diff options
author | Bhumika Goyal <bhumirks@gmail.com> | 2017-02-21 21:41:17 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-02-22 23:39:09 +0300 |
commit | 0ccea2210c7ed486c688cd05fd1b674d95ef9894 (patch) | |
tree | b10741d7f1cccde418f2a7dfd1db73764365f7a3 /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | a577ca6badb5261d3fa1bcbb3332ae7874f1a3a2 (diff) | |
download | linux-0ccea2210c7ed486c688cd05fd1b674d95ef9894.tar.xz |
qlogic: qlcnic_sysfs: constify bin_attribute structures
Declare bin_attribute structures as const as they are only passed as an
arguments to the functions device_remove_bin_file and
device_create_bin_file. These function arguments are of type const, so
bin_attribute structures having this property can be made const too.
Done using Coccinelle:
@r1 disable optional_qualifier @
identifier i;
position p;
@@
static struct bin_attribute i@p = {...};
@ok1@
identifier r1.i;
position p,p1;
@@
(
device_remove_bin_file(...,&i@p)
|
device_create_bin_file(..., &i@p1)
)
@bad@
position p!={r1.p,ok1.p,ok1.p1};
identifier r1.i;
@@
i@p
@depends on !bad disable optional_qualifier@
identifier r1.i;
@@
+const
struct bin_attribute i;
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions