From 839f12434c7618d326b9d1ece5eca643e5e48d0a Mon Sep 17 00:00:00 2001 From: Roland Dreier Date: Thu, 27 Sep 2012 09:23:41 -0700 Subject: mlx4_core: Stash PCI ID driver_data in mlx4_priv structure That way we can check flags later on, when we've finished with the pci_device_id structure. Also convert the "is VF" flag to an enum: "Never do in the preprocessor what can be done in C." Signed-off-by: Roland Dreier --- drivers/net/ethernet/mellanox/mlx4/mlx4.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'drivers/net/ethernet/mellanox/mlx4/mlx4.h') diff --git a/drivers/net/ethernet/mellanox/mlx4/mlx4.h b/drivers/net/ethernet/mellanox/mlx4/mlx4.h index 71eed05426ec..ac58189ae6da 100644 --- a/drivers/net/ethernet/mellanox/mlx4/mlx4.h +++ b/drivers/net/ethernet/mellanox/mlx4/mlx4.h @@ -768,6 +768,10 @@ struct _rule_hw { }; }; +enum { + MLX4_PCI_DEV_IS_VF = 1 << 0, +}; + struct mlx4_priv { struct mlx4_dev dev; @@ -775,6 +779,8 @@ struct mlx4_priv { struct list_head ctx_list; spinlock_t ctx_lock; + int pci_dev_data; + struct list_head pgdir_list; struct mutex pgdir_mutex; -- cgit v1.2.3