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


Groups > linux.kernel > #1632438

Re: [PATCH] block: hide badblocks attribute by default

From "Verma, Vishal L" <vishal.l.verma@intel.com>
Newsgroups linux.kernel
Subject Re: [PATCH] block: hide badblocks attribute by default
Date 2017-04-28 01:20 +0200
Message-ID <tB0Rz-7yS-5@gated-at.bofh.it> (permalink)
References <tAZCa-6zp-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, 2017-04-27 at 14:46 -0700, Dan Williams wrote:
> Commit 99e6608c9e74 "block: Add badblock management for gendisks"
> allowed for drivers like pmem and software-raid to advertise a list of
> bad media areas. However, it inadvertently added a 'badblocks' to all
> block devices. Lets clean this up by having the 'badblocks' attribute
> not be visible when the driver has not populated a 'struct badblocks'
> instance in the gendisk.
> 
> Cc: Jens Axboe <axboe@fb.com>
> Cc: Christoph Hellwig <hch@lst.de>
> Cc: Martin K. Petersen <martin.petersen@oracle.com>
> Reported-by: Vishal Verma <vishal.l.verma@intel.com>
> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
> ---
>  block/genhd.c |   11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
Tested that this removes the badblocks attribute for block devices that
don't use them:

$ cat /sys/block/pmem6/badblocks 
61576 8

$ cat /sys/block/vda/badblocks 
cat: /sys/block/vda/badblocks: No such file or directory

Tested-by: Vishal Verma <vishal.l.verma@intel.com>

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


Thread

[PATCH] block: hide badblocks attribute by default Dan Williams <dan.j.williams@intel.com> - 2017-04-28 00:00 +0200
  Re: [PATCH] block: hide badblocks attribute by default "Verma, Vishal L" <vishal.l.verma@intel.com> - 2017-04-28 01:20 +0200
  Re: [PATCH] block: hide badblocks attribute by default Jens Axboe <axboe@kernel.dk> - 2017-04-28 16:30 +0200

csiph-web