[RFC PATCH 00/18] block: add and use init disk helper

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Add and use the helper to initialize the common fields of struct gendisk
such as major, first_minor, minors, disk_name, private_data, and ops.
This initialization is spread all over the block drivers. This avoids
code repetation of inialization code of gendisk in current block drivers
and any future ones.

-ck

Chaitanya Kulkarni (18):
  block: add and use init disk helper
  nfblock: use init disk helper
  amiflop: use init disk helper
  brd: use init disk helper
  drbd: use init disk helper
  floppy: use init disk helper
  loop: use init disk helper
  n64cart: use init disk helper
  nbd: use init disk helper
  pcd: use init disk helper
  pd: use init disk helper
  pf: use init disk helper
  pktcdvd: use init disk helper
  rnbd-clt: use init disk helper
  swim: use init disk helper
  swim3: use init disk helper
  z2ram: use init disk helper
  ubi: use init disk helper

 arch/m68k/emu/nfblock.c        |  8 ++------
 block/genhd.c                  | 13 +++++++++++++
 drivers/block/amiflop.c        |  8 ++------
 drivers/block/ataflop.c        |  8 ++------
 drivers/block/brd.c            |  9 ++-------
 drivers/block/drbd/drbd_main.c |  6 +-----
 drivers/block/floppy.c         |  8 ++------
 drivers/block/loop.c           |  7 ++-----
 drivers/block/n64cart.c        |  4 +---
 drivers/block/nbd.c            |  7 ++-----
 drivers/block/null_blk/main.c  | 12 ++++--------
 drivers/block/paride/pcd.c     |  5 +----
 drivers/block/paride/pd.c      |  8 ++------
 drivers/block/paride/pf.c      |  6 +-----
 drivers/block/pktcdvd.c        |  6 +-----
 drivers/block/rnbd/rnbd-clt.c  |  9 +++------
 drivers/block/swim.c           |  7 ++-----
 drivers/block/swim3.c          |  8 ++------
 drivers/block/z2ram.c          |  5 +----
 drivers/mtd/ubi/block.c        |  6 +-----
 include/linux/blkdev.h         |  5 +++++
 21 files changed, 52 insertions(+), 103 deletions(-)

-- 
2.29.0




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux