linux/drivers/block
Alex Elder 7ef3214af2 rbd: don't allocate mon_addrs buffer in rbd_add()
The mon_addrs buffer in rbd_add is used to hold a copy of the
monitor IP addresses supplied via /sys/bus/rbd/add.  That is
passed to rbd_get_client(), which never modifies it (nor do
any of the functions it gets passed to thereafter)--the mon_addr
parameter to rbd_get_client() is a pointer to constant data, so it
can't be modifed.  Furthermore, rbd_get_client() has the length of
the mon_addrs buffer and that is used to ensure nothing goes beyond
its end.

Based on all this, there is no reason that a buffer needs to
be used to hold a copy of the mon_addrs provided via
/sys/bus/rbd/add.   Instead, the location within that passed-in
buffer can be provided, along with the length of the "token"
therein which represents the monitor IP's.

A small change to rbd_add_parse_args() allows the address within the
buffer to be passed back, and the length is already returned.  This
now means that, at least from the perspective of this interface,
there is no such thing as a list of monitor addresses that is too
long.

Signed-off-by: Alex Elder <elder@dreamhost.com>
2012-03-22 10:47:50 -05:00
..
aoe switch device_get_devnode() and ->devnode() to umode_t * 2012-01-03 22:54:55 -05:00
drbd module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
mtip32xx mtip32xx: removed the irrelevant argument of mtip_hw_submit_io() and the unused member of struct driver_data 2012-02-07 07:54:31 +01:00
paride paride/pcd: fix bool verbose module parameter. 2012-01-13 09:32:26 +10:30
xen-blkback Merge branch 'for-3.3/drivers' of git://git.kernel.dk/linux-block 2012-01-15 12:48:41 -08:00
amiflop.c fs: move code out of buffer.c 2012-01-03 22:54:07 -05:00
ataflop.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
brd.c fs: move code out of buffer.c 2012-01-03 22:54:07 -05:00
cciss_cmd.h cciss: use new doorbell-bit-5 reset method 2011-05-06 08:23:55 -06:00
cciss_scsi.c cciss: auto engage SCSI mid layer at driver load time 2011-11-16 09:21:49 +01:00
cciss_scsi.h cciss: add cciss_tape_cmds module paramter 2011-05-06 08:23:59 -06:00
cciss.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
cciss.h cciss: Adds simple mode functionality 2011-08-08 11:40:15 +02:00
cpqarray.c drivers/block/cpqarray.c: use pci_dev->revision 2011-09-21 10:02:13 +02:00
cpqarray.h
cryptoloop.c
DAC960.c drivers/block/DAC960: fix -Wuninitialized warning 2012-03-02 10:48:35 +01:00
DAC960.h
floppy.c floppy/scsi: fix setting of BIO flags 2012-03-05 15:49:43 -08:00
hd.c i8253: Create linux/i8253.h and use it in all 8253 related files 2011-06-09 15:01:37 +02:00
ida_cmd.h
ida_ioctl.h
Kconfig Merge git://git.infradead.org/users/willy/linux-nvme 2012-01-18 12:34:09 -08:00
loop.c loop: zero fill bio instead of return -EIO for partial read 2012-02-08 22:07:19 +01:00
Makefile Merge git://git.infradead.org/users/willy/linux-nvme 2012-01-18 12:34:09 -08:00
mg_disk.c
nbd.c nbd-replace-some-printk-with-dev_warn-and-dev_info-checkpatch-fixes 2011-08-19 14:48:28 +02:00
nvme.c asm-generic: architecture independent readq/writeq for 32bit environment 2012-02-21 16:47:28 -08:00
osdblk.c
pktcdvd.c switch device_get_devnode() and ->devnode() to umode_t * 2012-01-03 22:54:55 -05:00
ps3disk.c block: Fix files that are modules and hence need module.h 2011-10-31 19:31:13 -04:00
ps3vram.c Merge branch 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux 2011-11-06 19:44:47 -08:00
rbd_types.h rbd: introduce rados block device (rbd), based on libceph 2010-10-20 15:38:13 -07:00
rbd.c rbd: don't allocate mon_addrs buffer in rbd_add() 2012-03-22 10:47:50 -05:00
smart1,2.h fix typos 'comamnd' -> 'command' in comments 2011-02-02 11:31:21 +01:00
sunvdc.c
swim3.c block/swim3: Locking fixes 2011-12-12 12:42:12 +01:00
swim_asm.S
swim.c m68k/mac: cleanup forward declarations 2011-12-10 19:52:46 +01:00
sx8.c block, sx8: fix pointer math issue getting fw version 2012-03-03 19:44:39 +01:00
ub.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
umem.c block: remove support for bio remapping from ->make_request 2011-09-12 12:12:01 +02:00
umem.h
viodasd.c Fix common misspellings 2011-03-31 11:26:23 -03:00
virtio_blk.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
xd.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
xd.h
xen-blkfront.c Merge branch 'for-3.3/drivers' of git://git.kernel.dk/linux-block 2012-01-15 12:48:41 -08:00
xsysace.c block: xsysace: Don't use NO_IRQ 2012-01-05 08:34:29 +01:00
z2ram.c drivers/block/z2ram.c: correct printing of sector_t 2010-10-28 06:15:26 -06:00