Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1434458

[PATCH v4 0/4] nbd: nbd fixes

From "Pranay Kr. Srivastava" <pranjas@gmail.com>
Newsgroups linux.kernel
Subject [PATCH v4 0/4] nbd: nbd fixes
Date 2016-06-30 13:10 +0200
Message-ID <rPI14-pM-9@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


This patch series fixes the following

1) cleanup nbd_set_socket
   Simple fixes to nbd_set_socket.

2) fix might_sleep warning on socket shutdown:
   Fix sock_shutdown to avoid calling kernel_sock_shutdown
   while holding spin_lock.

3) make nbd device wait for its users.
   When a timeout or error occurs then nbd driver simply kills
   the block device. Many filesystem(s) example ext2/ext3 don't
   expect their buffer heads to disappear like that. Fix this
   by making nbd device wait for its users.

   The same work function is used to trigger the kill_bdev as well
   do a sock_shutdown, depending on either a timeout/error occured
   or a disconnect was issued.

   Also avoid scheduling the work_fn in case a timeout for a request
   has already occured.

4) use i_size_write to assign nbd device size
   Instead of directly assigning nbd block device
   size, use i_size_write for modification.

Pranay Kr. Srivastava (4):
  cleanup nbd_set_socket
  fix might_sleep warning on socket shutdown
  make nbd device wait for its users
  use i_size_write to assign nbd device size

 drivers/block/nbd.c | 168 ++++++++++++++++++++++++++++++++++++++--------------
 1 file changed, 123 insertions(+), 45 deletions(-)

Changelog:

*) Rebased all patches above on git://git.pengutronix.de/git/mpa/linux-nbd.git,
   commit:7ed71a8704eda7b75fbd0ed73fd0a5b6e469d250

*) Formatting issues, and removed unnecessary code.

*) Splitted the patch to wait for users to create a new patch
   4) use i_size_write to assign nbd device size

-- 
1.9.1

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH v4 0/4] nbd: nbd fixes "Pranay Kr. Srivastava" <pranjas@gmail.com> - 2016-06-30 13:10 +0200
  [PATCH v4 1/5]nbd: cleanup nbd_set_socket "Pranay Kr. Srivastava" <pranjas@gmail.com> - 2016-06-30 13:10 +0200
    Re: [PATCH v4 1/5]nbd: cleanup nbd_set_socket Pranay Srivastava <pranjas@gmail.com> - 2016-07-07 17:00 +0200
      Re: [PATCH v4 1/5]nbd: cleanup nbd_set_socket Pranay Srivastava <pranjas@gmail.com> - 2016-07-09 09:40 +0200
  [PATCH v4 3/5]nbd: make nbd device wait for its users "Pranay Kr. Srivastava" <pranjas@gmail.com> - 2016-06-30 13:10 +0200
  [PATCH v4 4/5]nbd: use i_size_write to assign nbd device size "Pranay Kr. Srivastava" <pranjas@gmail.com> - 2016-06-30 13:10 +0200
  [PATCH v4 2/5]nbd: fix might_sleep warning on socket shutdown "Pranay Kr. Srivastava" <pranjas@gmail.com> - 2016-06-30 13:10 +0200
    Re: [PATCH v4 2/5]nbd: fix might_sleep warning on socket shutdown Pranay Srivastava <pranjas@gmail.com> - 2016-07-04 09:10 +0200

csiph-web