diff options
author | Dean Nelson <dcn@sgi.com> | 2008-07-30 01:34:16 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-30 12:41:50 -0400 |
commit | a812dcc3a298eef650c381e094e2cf41a4ecc9ad (patch) | |
tree | cb6a24a623891054789f5340742c3c8ff1fb8cde /drivers/misc/sgi-xp/xpc.h | |
parent | 261f3b4979db88d29fc86aad9f76fbc0c2c6d21a (diff) |
sgi-xp: add usage of GRU driver by xpc_remote_memcpy()
Add UV support to xpc_remote_memcpy(), which involves interfacing to the
GRU driver.
Signed-off-by: Dean Nelson <dcn@sgi.com>
Cc: Jack Steiner <steiner@sgi.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/misc/sgi-xp/xpc.h')
-rw-r--r-- | drivers/misc/sgi-xp/xpc.h | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/drivers/misc/sgi-xp/xpc.h b/drivers/misc/sgi-xp/xpc.h index 96408fcf5a1e..49e26993345b 100644 --- a/drivers/misc/sgi-xp/xpc.h +++ b/drivers/misc/sgi-xp/xpc.h | |||
@@ -91,8 +91,8 @@ struct xpc_rsvd_page { | |||
91 | u8 version; | 91 | u8 version; |
92 | u8 pad1[3]; /* align to next u64 in 1st 64-byte cacheline */ | 92 | u8 pad1[3]; /* align to next u64 in 1st 64-byte cacheline */ |
93 | union { | 93 | union { |
94 | u64 vars_pa; /* physical address of struct xpc_vars */ | 94 | unsigned long vars_pa; /* phys address of struct xpc_vars */ |
95 | u64 activate_mq_gpa; /* global phys address of activate_mq */ | 95 | unsigned long activate_mq_gpa; /* gru phy addr of activate_mq */ |
96 | } sn; | 96 | } sn; |
97 | unsigned long ts_jiffies; /* timestamp when rsvd pg was setup by XPC */ | 97 | unsigned long ts_jiffies; /* timestamp when rsvd pg was setup by XPC */ |
98 | u64 pad2[10]; /* align to last u64 in 2nd 64-byte cacheline */ | 98 | u64 pad2[10]; /* align to last u64 in 2nd 64-byte cacheline */ |
@@ -122,8 +122,8 @@ struct xpc_vars_sn2 { | |||
122 | u64 heartbeat_offline; /* if 0, heartbeat should be changing */ | 122 | u64 heartbeat_offline; /* if 0, heartbeat should be changing */ |
123 | int activate_IRQ_nasid; | 123 | int activate_IRQ_nasid; |
124 | int activate_IRQ_phys_cpuid; | 124 | int activate_IRQ_phys_cpuid; |
125 | u64 vars_part_pa; | 125 | unsigned long vars_part_pa; |
126 | u64 amos_page_pa; /* paddr of page of amos from MSPEC driver */ | 126 | unsigned long amos_page_pa;/* paddr of page of amos from MSPEC driver */ |
127 | struct amo *amos_page; /* vaddr of page of amos from MSPEC driver */ | 127 | struct amo *amos_page; /* vaddr of page of amos from MSPEC driver */ |
128 | }; | 128 | }; |
129 | 129 | ||
@@ -142,10 +142,10 @@ struct xpc_vars_sn2 { | |||
142 | struct xpc_vars_part_sn2 { | 142 | struct xpc_vars_part_sn2 { |
143 | u64 magic; | 143 | u64 magic; |
144 | 144 | ||
145 | u64 openclose_args_pa; /* physical address of open and close args */ | 145 | unsigned long openclose_args_pa; /* phys addr of open and close args */ |
146 | u64 GPs_pa; /* physical address of Get/Put values */ | 146 | unsigned long GPs_pa; /* physical address of Get/Put values */ |
147 | 147 | ||
148 | u64 chctl_amo_pa; /* physical address of chctl flags' amo */ | 148 | unsigned long chctl_amo_pa; /* physical address of chctl flags' amo */ |
149 | 149 | ||
150 | int notify_IRQ_nasid; /* nasid of where to send notify IRQs */ | 150 | int notify_IRQ_nasid; /* nasid of where to send notify IRQs */ |
151 | int notify_IRQ_phys_cpuid; /* CPUID of where to send notify IRQs */ | 151 | int notify_IRQ_phys_cpuid; /* CPUID of where to send notify IRQs */ |
@@ -213,7 +213,7 @@ struct xpc_openclose_args { | |||
213 | u16 msg_size; /* sizeof each message entry */ | 213 | u16 msg_size; /* sizeof each message entry */ |
214 | u16 remote_nentries; /* #of message entries in remote msg queue */ | 214 | u16 remote_nentries; /* #of message entries in remote msg queue */ |
215 | u16 local_nentries; /* #of message entries in local msg queue */ | 215 | u16 local_nentries; /* #of message entries in local msg queue */ |
216 | u64 local_msgqueue_pa; /* physical address of local message queue */ | 216 | unsigned long local_msgqueue_pa; /* phys addr of local message queue */ |
217 | }; | 217 | }; |
218 | 218 | ||
219 | #define XPC_OPENCLOSE_ARGS_SIZE \ | 219 | #define XPC_OPENCLOSE_ARGS_SIZE \ |
@@ -366,8 +366,8 @@ struct xpc_channel { | |||
366 | void *remote_msgqueue_base; /* base address of kmalloc'd space */ | 366 | void *remote_msgqueue_base; /* base address of kmalloc'd space */ |
367 | struct xpc_msg *remote_msgqueue; /* cached copy of remote partition's */ | 367 | struct xpc_msg *remote_msgqueue; /* cached copy of remote partition's */ |
368 | /* local message queue */ | 368 | /* local message queue */ |
369 | u64 remote_msgqueue_pa; /* phys addr of remote partition's */ | 369 | unsigned long remote_msgqueue_pa; /* phys addr of remote partition's */ |
370 | /* local message queue */ | 370 | /* local message queue */ |
371 | 371 | ||
372 | atomic_t references; /* #of external references to queues */ | 372 | atomic_t references; /* #of external references to queues */ |
373 | 373 | ||
@@ -491,12 +491,12 @@ xpc_any_msg_chctl_flags_set(union xpc_channel_ctl_flags *chctl) | |||
491 | */ | 491 | */ |
492 | 492 | ||
493 | struct xpc_partition_sn2 { | 493 | struct xpc_partition_sn2 { |
494 | u64 remote_amos_page_pa; /* phys addr of partition's amos page */ | 494 | unsigned long remote_amos_page_pa; /* paddr of partition's amos page */ |
495 | int activate_IRQ_nasid; /* active partition's act/deact nasid */ | 495 | int activate_IRQ_nasid; /* active partition's act/deact nasid */ |
496 | int activate_IRQ_phys_cpuid; /* active part's act/deact phys cpuid */ | 496 | int activate_IRQ_phys_cpuid; /* active part's act/deact phys cpuid */ |
497 | 497 | ||
498 | u64 remote_vars_pa; /* phys addr of partition's vars */ | 498 | unsigned long remote_vars_pa; /* phys addr of partition's vars */ |
499 | u64 remote_vars_part_pa; /* phys addr of partition's vars part */ | 499 | unsigned long remote_vars_part_pa; /* paddr of partition's vars part */ |
500 | u8 remote_vars_version; /* version# of partition's vars */ | 500 | u8 remote_vars_version; /* version# of partition's vars */ |
501 | 501 | ||
502 | void *local_GPs_base; /* base address of kmalloc'd space */ | 502 | void *local_GPs_base; /* base address of kmalloc'd space */ |
@@ -504,10 +504,10 @@ struct xpc_partition_sn2 { | |||
504 | void *remote_GPs_base; /* base address of kmalloc'd space */ | 504 | void *remote_GPs_base; /* base address of kmalloc'd space */ |
505 | struct xpc_gp_sn2 *remote_GPs; /* copy of remote partition's local */ | 505 | struct xpc_gp_sn2 *remote_GPs; /* copy of remote partition's local */ |
506 | /* Get/Put values */ | 506 | /* Get/Put values */ |
507 | u64 remote_GPs_pa; /* phys address of remote partition's local */ | 507 | unsigned long remote_GPs_pa; /* phys addr of remote partition's local */ |
508 | /* Get/Put values */ | 508 | /* Get/Put values */ |
509 | 509 | ||
510 | u64 remote_openclose_args_pa; /* phys addr of remote's args */ | 510 | unsigned long remote_openclose_args_pa; /* phys addr of remote's args */ |
511 | 511 | ||
512 | int notify_IRQ_nasid; /* nasid of where to send notify IRQs */ | 512 | int notify_IRQ_nasid; /* nasid of where to send notify IRQs */ |
513 | int notify_IRQ_phys_cpuid; /* CPUID of where to send notify IRQs */ | 513 | int notify_IRQ_phys_cpuid; /* CPUID of where to send notify IRQs */ |
@@ -529,7 +529,7 @@ struct xpc_partition { | |||
529 | 529 | ||
530 | u8 remote_rp_version; /* version# of partition's rsvd pg */ | 530 | u8 remote_rp_version; /* version# of partition's rsvd pg */ |
531 | unsigned long remote_rp_ts_jiffies; /* timestamp when rsvd pg setup */ | 531 | unsigned long remote_rp_ts_jiffies; /* timestamp when rsvd pg setup */ |
532 | u64 remote_rp_pa; /* phys addr of partition's rsvd pg */ | 532 | unsigned long remote_rp_pa; /* phys addr of partition's rsvd pg */ |
533 | u64 last_heartbeat; /* HB at last read */ | 533 | u64 last_heartbeat; /* HB at last read */ |
534 | u32 activate_IRQ_rcvd; /* IRQs since activation */ | 534 | u32 activate_IRQ_rcvd; /* IRQs since activation */ |
535 | spinlock_t act_lock; /* protect updating of act_state */ | 535 | spinlock_t act_lock; /* protect updating of act_state */ |
@@ -623,7 +623,8 @@ extern void xpc_activate_partition(struct xpc_partition *); | |||
623 | extern void xpc_activate_kthreads(struct xpc_channel *, int); | 623 | extern void xpc_activate_kthreads(struct xpc_channel *, int); |
624 | extern void xpc_create_kthreads(struct xpc_channel *, int, int); | 624 | extern void xpc_create_kthreads(struct xpc_channel *, int, int); |
625 | extern void xpc_disconnect_wait(int); | 625 | extern void xpc_disconnect_wait(int); |
626 | extern enum xp_retval (*xpc_get_partition_rsvd_page_pa) (u64, u64 *, u64 *, | 626 | extern enum xp_retval (*xpc_get_partition_rsvd_page_pa) (void *, u64 *, |
627 | unsigned long *, | ||
627 | size_t *); | 628 | size_t *); |
628 | extern enum xp_retval (*xpc_rsvd_page_init) (struct xpc_rsvd_page *); | 629 | extern enum xp_retval (*xpc_rsvd_page_init) (struct xpc_rsvd_page *); |
629 | extern void (*xpc_heartbeat_init) (void); | 630 | extern void (*xpc_heartbeat_init) (void); |
@@ -640,8 +641,8 @@ extern void (*xpc_notify_senders_of_disconnect) (struct xpc_channel *); | |||
640 | extern void (*xpc_process_msg_chctl_flags) (struct xpc_partition *, int); | 641 | extern void (*xpc_process_msg_chctl_flags) (struct xpc_partition *, int); |
641 | extern int (*xpc_n_of_deliverable_msgs) (struct xpc_channel *); | 642 | extern int (*xpc_n_of_deliverable_msgs) (struct xpc_channel *); |
642 | extern struct xpc_msg *(*xpc_get_deliverable_msg) (struct xpc_channel *); | 643 | extern struct xpc_msg *(*xpc_get_deliverable_msg) (struct xpc_channel *); |
643 | extern void (*xpc_request_partition_activation) (struct xpc_rsvd_page *, u64, | 644 | extern void (*xpc_request_partition_activation) (struct xpc_rsvd_page *, |
644 | int); | 645 | unsigned long, int); |
645 | extern void (*xpc_request_partition_reactivation) (struct xpc_partition *); | 646 | extern void (*xpc_request_partition_reactivation) (struct xpc_partition *); |
646 | extern void (*xpc_request_partition_deactivation) (struct xpc_partition *); | 647 | extern void (*xpc_request_partition_deactivation) (struct xpc_partition *); |
647 | extern void (*xpc_cancel_partition_deactivation_request) ( | 648 | extern void (*xpc_cancel_partition_deactivation_request) ( |
@@ -690,7 +691,8 @@ extern enum xp_retval xpc_mark_partition_active(struct xpc_partition *); | |||
690 | extern void xpc_mark_partition_inactive(struct xpc_partition *); | 691 | extern void xpc_mark_partition_inactive(struct xpc_partition *); |
691 | extern void xpc_discovery(void); | 692 | extern void xpc_discovery(void); |
692 | extern enum xp_retval xpc_get_remote_rp(int, unsigned long *, | 693 | extern enum xp_retval xpc_get_remote_rp(int, unsigned long *, |
693 | struct xpc_rsvd_page *, u64 *); | 694 | struct xpc_rsvd_page *, |
695 | unsigned long *); | ||
694 | extern void xpc_deactivate_partition(const int, struct xpc_partition *, | 696 | extern void xpc_deactivate_partition(const int, struct xpc_partition *, |
695 | enum xp_retval); | 697 | enum xp_retval); |
696 | extern enum xp_retval xpc_initiate_partid_to_nasids(short, void *); | 698 | extern enum xp_retval xpc_initiate_partid_to_nasids(short, void *); |