diff options
author | Jack Morgenstein <jackm@dev.mellanox.co.il> | 2014-07-28 20:30:23 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-07-30 21:00:06 (GMT) |
commit | f241e7497ec2d22b83002b17ae91a851d4034cb7 (patch) | |
tree | 5d8179647f85be21bad567cdce578a78ca6de875 /drivers/net/ethernet/mellanox/mlx5/core/port.c | |
parent | 9603b61de1eee92977d74ff42541be20c0c5b1a7 (diff) | |
download | linux-f241e7497ec2d22b83002b17ae91a851d4034cb7.tar.xz |
mlx5: minor fixes (mainly avoidance of hidden casts)
There were many places where parameters which should be u8/u16 were
integer type.
Additionally, in 2 places, a check for a non-null pointer was added
before dereferencing the pointer (this is actually a bug fix).
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Eli Cohen <eli@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/port.c')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/port.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/port.c b/drivers/net/ethernet/mellanox/mlx5/core/port.c index 8c9ac87..3139658 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/port.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/port.c @@ -86,7 +86,7 @@ struct mlx5_reg_pcap { __be32 caps_31_0; }; -int mlx5_set_port_caps(struct mlx5_core_dev *dev, int port_num, u32 caps) +int mlx5_set_port_caps(struct mlx5_core_dev *dev, u8 port_num, u32 caps) { struct mlx5_reg_pcap in; struct mlx5_reg_pcap out; |