mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-25 10:42:21 +03:00
nvethernet: Address dev_addr warnings in K5.17
dev_addr present in struct net_device is made const from K5.17.So, modifying the local pointer also to const. Bug 4076818 Change-Id: I7f2f0a5fab033a13145a0d5a60f2847d239cedb4 Signed-off-by: Revanth Kumar Uppala <ruppala@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2898041 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com> Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com> GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
2c2e1dfb9e
commit
8229868ec8
@@ -10,7 +10,11 @@
|
||||
*/
|
||||
struct ether_packet_ctxt {
|
||||
/** Destination MAC address in Ethernet header */
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 17, 0)
|
||||
const unsigned char *dst;
|
||||
#else
|
||||
unsigned char *dst;
|
||||
#endif
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -150,7 +154,11 @@ static int ether_test_loopback_validate(struct sk_buff *skb,
|
||||
struct net_device *orig_ndev)
|
||||
{
|
||||
struct ether_test_priv_data *tpdata = pt->af_packet_priv;
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 17, 0)
|
||||
const unsigned char *dst = tpdata->ctxt->dst;
|
||||
#else
|
||||
unsigned char *dst = tpdata->ctxt->dst;
|
||||
#endif
|
||||
struct ether_testhdr *thdr;
|
||||
struct ethhdr *ehdr;
|
||||
struct udphdr *uhdr;
|
||||
|
||||
Reference in New Issue
Block a user