aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/moxa
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2017-07-28 18:52:57 -0700
committerDavid S. Miller <davem@davemloft.net>2017-07-28 18:52:57 -0700
commitbdb0effcc0a9e636c0a5406bc2eb78474436143d (patch)
tree330a4946c3c78f542f8c217441841cdfeefe546b /drivers/net/ethernet/moxa
parentMerge branch 'liquidio-standardization-and-cleanup' (diff)
parentl2tp: constify inet6_protocol structures (diff)
downloadlinux-dev-bdb0effcc0a9e636c0a5406bc2eb78474436143d.tar.xz
linux-dev-bdb0effcc0a9e636c0a5406bc2eb78474436143d.zip
Merge branch 'inet6_protocol-const'
Julia Lawall says: ==================== constify inet6_protocol structures The inet6_protocol structure is only passed as the first argument to inet6_add_protocol or inet6_del_protocol, both of which are declared as const. Thus the inet6_protocol structure itself can be const. Done with the help of Coccinelle. // <smpl> @r disable optional_qualifier@ identifier i; position p; @@ static struct inet6_protocol i@p = { ... }; @ok1@ identifier r.i; expression e1; position p; @@ \(inet6_add_protocol\|inet6_del_protocol\)(&i@p,...) @bad@ position p != {r.p,ok1.p}; identifier r.i; struct inet6_protocol e; @@ e@i@p @depends on !bad disable optional_qualifier@ identifier r.i; @@ static +const struct inet6_protocol i = { ... }; // </smpl> ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/moxa')
0 files changed, 0 insertions, 0 deletions