diff options
author | Vaishali Thakkar <vthakkar1994@gmail.com> | 2015-06-24 07:42:13 +0300 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2015-07-14 20:20:09 +0300 |
commit | b356c1c1f90a347b6f67d9272dda7ecf47e0b46c (patch) | |
tree | 3de425b80bc6a68d7924ca01ac385462733e34a5 /include/scsi/scsi_transport_srp.h | |
parent | 3b8ab700af0a5c5e59c833f8a88f94b97499f5e5 (diff) | |
download | linux-b356c1c1f90a347b6f67d9272dda7ecf47e0b46c.tar.xz |
IB/srpt: Convert use of __constant_cpu_to_beXX to cpu_to_beXX
In little endian cases, the macro cpu_to_be{16,32,64} unfolds to
__swab{16,32,64} which provides special case for constants. In
big endian cases, __constant_cpu_to_be{16,32,64} and
cpu_to_be{16,32,64} expand directly to the same expression. So,
replace __constant_cpu_to_be{16,32,64} with cpu_to_be{16,32,64}
with the goal of getting rid of the definitions of
__constant_cpu_to_be{16,32,64} completely.
The Coccinelle semantic patch that performs this transformation
is as follows:
@@expression x;@@
(
- __constant_cpu_to_be16(x)
+ cpu_to_be16(x)
|
- __constant_cpu_to_be32(x)
+ cpu_to_be32(x)
|
- __constant_cpu_to_be64(x)
+ cpu_to_be64(x)
)
Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com>
Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'include/scsi/scsi_transport_srp.h')
0 files changed, 0 insertions, 0 deletions