~ubuntu-core-dev/module-init-tools/ubuntu

« back to all changes in this revision

Viewing changes to tests/data/src/complex_c.c

  • Committer: Scott James Remnant
  • Date: 2009-07-16 15:24:17 UTC
  • mfrom: (152.1.38)
  • Revision ID: scott@netsplit.com-20090716152417-7ak1sklxb59cs4fz
MergeĀ 3.10

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* A depends on B, C and D.  B depends on E.  C depends on B and E.  D
2
2
   depends on B. */
 
3
#include "module.h"
 
4
 
3
5
int c;
4
6
extern int b, e;
5
7
 
8
10
        c = b = e = 0;
9
11
}
10
12
 
11
 
#define MODULE_NAME_LEN (64 - sizeof(unsigned long))
12
 
struct kernel_symbol
13
 
{
14
 
        unsigned long value;
15
 
        char name[MODULE_NAME_LEN];
16
 
};
17
 
 
18
 
#define EXPORT_SYMBOL(sym)                              \
19
 
        const struct kernel_symbol __ksymtab_##sym      \
20
 
        __attribute__((section("__ksymtab")))           \
21
 
        = { (unsigned long)&sym, #sym }
22
13
 
23
14
EXPORT_SYMBOL(c);
24
15