mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-21 03:33:59 +08:00
[NET]: Mark struct net_device * argument to netdev_priv const
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
b3d88ad49a
commit
6472ce6096
@ -546,7 +546,7 @@ struct net_device
|
|||||||
#define NETDEV_ALIGN 32
|
#define NETDEV_ALIGN 32
|
||||||
#define NETDEV_ALIGN_CONST (NETDEV_ALIGN - 1)
|
#define NETDEV_ALIGN_CONST (NETDEV_ALIGN - 1)
|
||||||
|
|
||||||
static inline void *netdev_priv(struct net_device *dev)
|
static inline void *netdev_priv(const struct net_device *dev)
|
||||||
{
|
{
|
||||||
return (char *)dev + ((sizeof(struct net_device)
|
return (char *)dev + ((sizeof(struct net_device)
|
||||||
+ NETDEV_ALIGN_CONST)
|
+ NETDEV_ALIGN_CONST)
|
||||||
|
Loading…
Reference in New Issue
Block a user