]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
target: simplify backend attribute implementation
authorChristoph Hellwig <hch@lst.de>
Sun, 10 May 2015 16:14:58 +0000 (18:14 +0200)
committerNicholas Bellinger <nab@linux-iscsi.org>
Mon, 1 Jun 2015 07:25:38 +0000 (00:25 -0700)
commit3effdb9094fd06b9c61ecef08d610ae90805fd98
tree6b49994e6ca40e5c4cd2a3a391d6c930c1018ecf
parent5873c4d157400ade4052e9d7b6259fa592e1ddbf
target: simplify backend attribute implementation

Consolidate the implementation of the backend attributes in a single file
and single function per attribute show/store function instead of splitting
it into multiple functions in multiple files.

Also use the proper strto* helpers for exposed data types, add macros to
implement the store methods for the most common data types and share the
show methods between the two different attribute implementations.

(Fix bogus store_pi_prot_format flag=0 return value - nab)

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/target_core_configfs.c
drivers/target/target_core_device.c
include/target/target_core_backend.h