aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/netxen/netxen_nic.h
diff options
context:
space:
mode:
authorAmit S. Kale <amitkale@netxen.com>2007-02-12 07:33:38 -0500
committerJeff Garzik <jeff@garzik.org>2007-02-17 15:26:45 -0500
commit825811749b00f670b53e35ed342d5dc10d71c9de (patch)
treeededb5a33f1f21cab025f4bc6cf8e44429c37802 /drivers/net/netxen/netxen_nic.h
parent11cc3bb522ddb3962fb7134ffc5e27c487746193 (diff)
NetXen: Fix to get the driver working after sparse changes
Signed-off-by: Amit S. Kale <amitkale@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/netxen/netxen_nic.h')
-rw-r--r--drivers/net/netxen/netxen_nic.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/netxen/netxen_nic.h b/drivers/net/netxen/netxen_nic.h
index e021a30abd8..2807ef400fb 100644
--- a/drivers/net/netxen/netxen_nic.h
+++ b/drivers/net/netxen/netxen_nic.h
@@ -252,7 +252,7 @@ typedef u32 netxen_ctx_msg;
252#define netxen_set_msg_ctxid(config_word, val) \ 252#define netxen_set_msg_ctxid(config_word, val) \
253 ((config_word) &= ~(0x3ff<<18), (config_word) |= (val & 0x3ff) << 18) 253 ((config_word) &= ~(0x3ff<<18), (config_word) |= (val & 0x3ff) << 18)
254#define netxen_set_msg_opcode(config_word, val) \ 254#define netxen_set_msg_opcode(config_word, val) \
255 ((config_word) &= ~(0xf<<24), (config_word) |= (val & 0xf) << 24) 255 ((config_word) &= ~(0xf<<28), (config_word) |= (val & 0xf) << 28)
256 256
257struct netxen_rcv_context { 257struct netxen_rcv_context {
258 __le64 rcv_ring_addr; 258 __le64 rcv_ring_addr;
@@ -303,14 +303,14 @@ struct netxen_ring_ctx {
303 (cmd_desc)->flags_opcode |= cpu_to_le16((val) & 0x7f)) 303 (cmd_desc)->flags_opcode |= cpu_to_le16((val) & 0x7f))
304#define netxen_set_cmd_desc_opcode(cmd_desc, val) \ 304#define netxen_set_cmd_desc_opcode(cmd_desc, val) \
305 ((cmd_desc)->flags_opcode &= ~cpu_to_le16(0x3f<<7), \ 305 ((cmd_desc)->flags_opcode &= ~cpu_to_le16(0x3f<<7), \
306 (cmd_desc)->flags_opcode |= cpu_to_le16((val) & (0x3f<<7))) 306 (cmd_desc)->flags_opcode |= cpu_to_le16(((val & 0x3f)<<7)))
307 307
308#define netxen_set_cmd_desc_num_of_buff(cmd_desc, val) \ 308#define netxen_set_cmd_desc_num_of_buff(cmd_desc, val) \
309 ((cmd_desc)->num_of_buffers_total_length &= ~cpu_to_le32(0xff), \ 309 ((cmd_desc)->num_of_buffers_total_length &= ~cpu_to_le32(0xff), \
310 (cmd_desc)->num_of_buffers_total_length |= cpu_to_le32((val) & 0xff)) 310 (cmd_desc)->num_of_buffers_total_length |= cpu_to_le32((val) & 0xff))
311#define netxen_set_cmd_desc_totallength(cmd_desc, val) \ 311#define netxen_set_cmd_desc_totallength(cmd_desc, val) \
312 ((cmd_desc)->num_of_buffers_total_length &= cpu_to_le32(0xff), \ 312 ((cmd_desc)->num_of_buffers_total_length &= ~cpu_to_le32(0xffffff00), \
313 (cmd_desc)->num_of_buffers_total_length |= cpu_to_le32(val << 24)) 313 (cmd_desc)->num_of_buffers_total_length |= cpu_to_le32(val << 8))
314 314
315#define netxen_get_cmd_desc_opcode(cmd_desc) \ 315#define netxen_get_cmd_desc_opcode(cmd_desc) \
316 ((le16_to_cpu((cmd_desc)->flags_opcode) >> 7) & 0x003F) 316 ((le16_to_cpu((cmd_desc)->flags_opcode) >> 7) & 0x003F)