diff options
author | Michael Chan <mchan@broadcom.com> | 2010-02-24 09:42:08 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-26 05:10:14 -0500 |
commit | a4dde3abbf87a495154a876576e1ab34b17b5ef1 (patch) | |
tree | 0a1faff1e54932ebb616fc5f0e412b187a433e94 /drivers/net/cnic.h | |
parent | c76284af9ec8a010c502a70249cb74b3bb69ec6f (diff) |
cnic: Use union for the status blocks of different devices.
We only need to assign the status block address once and it also saves
space in the structure.
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: Eddie Wai <waie@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cnic.h')
-rw-r--r-- | drivers/net/cnic.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/net/cnic.h b/drivers/net/cnic.h index 1921597ab4a3..d566390b8c4d 100644 --- a/drivers/net/cnic.h +++ b/drivers/net/cnic.h | |||
@@ -224,9 +224,12 @@ struct cnic_local { | |||
224 | u16 kcq_prod_idx; | 224 | u16 kcq_prod_idx; |
225 | u32 kcq_io_addr; | 225 | u32 kcq_io_addr; |
226 | 226 | ||
227 | void *status_blk; | 227 | union { |
228 | struct status_block_msix *bnx2_status_blk; | 228 | void *gen; |
229 | struct host_status_block *bnx2x_status_blk; | 229 | struct status_block_msix *bnx2; |
230 | struct host_status_block *bnx2x; | ||
231 | } status_blk; | ||
232 | |||
230 | struct host_def_status_block *bnx2x_def_status_blk; | 233 | struct host_def_status_block *bnx2x_def_status_blk; |
231 | 234 | ||
232 | u32 status_blk_num; | 235 | u32 status_blk_num; |