Calling architecture specific headers files?
Abhishek Bist
ishubist at gmail.com
Tue May 5 10:00:11 EDT 2015
Hi,
I am searching the way out that how an architecture specific header's file come into existence.For example the
generic defination of spinlock is supposed to call architecture specific spinlock.
(linux/spinlock_types.h)
typedef struct raw_spinlock {
arch_spinlock_t raw_lock; <<<<
#ifdef CONFIG_GENERIC_LOCKBREAK
unsigned int break_lock;
#endif
#ifdef CONFIG_DEBUG_SPINLOCK
unsigned int magic, owner_cpu;
void *owner;
#endif
#ifdef CONFIG_DEBUG_LOCK_ALLOC
struct lockdep_map dep_map;
#endif
} raw_spinlock_t;
(x86/include/asm/spinlock_types.h)
typedef struct arch_spinlock {
union {
__ticketpair_t head_tail;
struct __raw_tickets {
__ticket_t head, tail;
} tickets;
};
} arch_spinlock_t;
what is there which makes to load the architecture specific spinlock (x86) in my case.
More information about the Kernelnewbies
mailing list