Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Christoph Hellwig
On Tue, Jun 25, 2019 at 01:54:21PM -0600, Logan Gunthorpe wrote: > Well whether it's dma_addr_t, phys_addr_t, pfn_t the result isn't all > that different. You still need roughly the same 'if' hooks for any > backed memory that isn't in the linear mapping and you can't get a > kernel mapping for dir

[PATCH V3 3/3] block: Limit zone array allocation size

2019-06-25 Thread Damien Le Moal
Limit the size of the struct blk_zone array used in blk_revalidate_disk_zones() to avoid memory allocation failures leading to disk revalidation failure. Further reduce the likelyhood of these failures by using kvmalloc() instead of directly allocating contiguous pages. Fixes: 515ce6061312 ("scsi:

[PATCH V3 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Damien Le Moal
To allow the SCSI subsystem scsi_execute_req() function to issue requests using large buffers that are better allocated with vmalloc() rather than kmalloc(), modify bio_map_kern() to allow passing a buffer allocated with the vmalloc() function. To do so, simply test the buffer address using is_vmal

[PATCH V3 0/3] Fix zone revalidation memory allocation failures

2019-06-25 Thread Damien Le Moal
This series addresses a reccuring problem with zone revalidation failures observed during extensive testing with memory constrained system and device hot-plugging. The problem source is failure to allocate large memory areas with alloc_pages() or kmalloc() in blk_revalidate_disk_zones() to store t

[PATCH V3 2/3] sd_zbc: Fix report zones buffer allocation

2019-06-25 Thread Damien Le Moal
During disk scan and revalidation done with sd_revalidate(), the zones of a zoned disk are checked using the helper function blk_revalidate_disk_zones() if a configuration change is detected (change in the number of zones or zone size). The function blk_revalidate_disk_zones() issues report_zones c

Re: [PATCH V2 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Damien Le Moal
Christoph, On 2019/06/26 15:10, Christoph Hellwig wrote: > On Wed, Jun 26, 2019 at 10:47:57AM +0900, Damien Le Moal wrote: >> @@ -1501,9 +1502,14 @@ struct bio *bio_map_kern(struct request_queue *q, >> void *data, unsigned int len, >> unsigned long end = (kaddr + len + PAGE_SIZE - 1) >> PAGE

Re: [PATCH V2 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Christoph Hellwig
On Wed, Jun 26, 2019 at 10:47:57AM +0900, Damien Le Moal wrote: > @@ -1501,9 +1502,14 @@ struct bio *bio_map_kern(struct request_queue *q, void > *data, unsigned int len, > unsigned long end = (kaddr + len + PAGE_SIZE - 1) >> PAGE_SHIFT; > unsigned long start = kaddr >> PAGE_SHIFT; >

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Chaitanya Kulkarni
On 6/25/19 6:38 PM, Damien Le Moal wrote: > On 2019/06/26 1:06, Chaitanya Kulkarni wrote: >> On 06/25/2019 08:59 AM, Bart Van Assche wrote: >>> On 6/24/19 8:24 PM, Chaitanya Kulkarni wrote: nit:- Can we use is_vmalloc_addr() call directly so that "if (is_vmalloc)" -> "if (is_vmalloc_addr

Re: [PATCH] bcache: make stripe_size configurable and persistent for hardware raid5/6

2019-06-25 Thread Martin K. Petersen
Eric, > * LSI 2108 (Supermicro) > * LSI 3108 (Dell) > * Areca 1882 > * Areca 1883 > * Fibrechannel 8gbe connected to a Storwize 3700 I have a 3108 that provides the BL VPD. Surprised the 1883 doesn't. As a rule of thumb, you need 12 Gbps SAS or 16 Gbps FC devices for the VPD page to be present

[PATCH V2 2/3] sd_zbc: Fix report zones buffer allocation

2019-06-25 Thread Damien Le Moal
During disk scan and revalidation done with sd_revalidate(), the zones of a zoned disk are checked using the helper function blk_revalidate_disk_zones() if a configuration change is detected (change in the number of zones or zone size). The function blk_revalidate_disk_zones() issues report_zones c

[PATCH V2 0/3] Fix zone revalidation memory allocation failures

2019-06-25 Thread Damien Le Moal
This series addresses a reccuring problem with zone revalidation failures observed during extensive testing with memory constrained system and device hot-plugging. The problem source is failure to allocate large memory areas with alloc_pages() or kmalloc() in blk_revalidate_disk_zones() to store t

[PATCH V2 3/3] block: Limit zone array allocation size

2019-06-25 Thread Damien Le Moal
Limit the size of the struct blk_zone array used in blk_revalidate_disk_zones() to avoid memory allocation failures leading to disk revalidation failure. Further reduce the likelyhood of these failures by using kvmalloc() instead of directly allocating contiguous pages. Fixes: 515ce6061312 ("scsi:

[PATCH V2 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Damien Le Moal
To allow the SCSI subsystem scsi_execute_req() function to issue requests using large buffers that are better allocated with vmalloc() rather than kmalloc(), modify bio_map_kern() to allow passing a buffer allocated with the vmalloc() function. To do so, simply test the buffer address using is_vmal

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Damien Le Moal
On 2019/06/26 1:06, Chaitanya Kulkarni wrote: > On 06/25/2019 08:59 AM, Bart Van Assche wrote: >> On 6/24/19 8:24 PM, Chaitanya Kulkarni wrote: >>> nit:- Can we use is_vmalloc_addr() call directly so that >>> "if (is_vmalloc)" -> "if (is_vmalloc_addr(data))" and remove is_vmalloc >>> variable. >>

Re: [PATCH] bcache: make stripe_size configurable and persistent for hardware raid5/6

2019-06-25 Thread Eric Wheeler
On Mon, 24 Jun 2019, Martin K. Petersen wrote: > > Perhaps they do not set stripe_width using io_opt? I did a grep to see > > if any of them did, but I didn't see them. How is stripe_width > > indicated by RAID controllers? > > The values are reported in the Block Limits VPD page for each SCSI blo

Re: [PATCH v2 0/3] block: sed-opal: add support for shadow MBR done flag and write

2019-06-25 Thread Derrick, Jonathan
These are still good with me and we'll likely have a similar future use for passing data through the ioctl. Could we get this staged for 5.3? On Tue, 2019-05-21 at 22:46 +0200, David Kozub wrote: > This patch series extends SED Opal support: it adds IOCTL for setting the > shadow > MBR done flag

Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Logan Gunthorpe
On 2019-06-25 11:01 a.m., Christoph Hellwig wrote: > On Tue, Jun 25, 2019 at 09:57:52AM -0600, Logan Gunthorpe wrote: >>> You assume all addressing is done by the PCI bus address. If a device >>> is addressing its own BAR there is no reason to use the PCI bus address, >>> as it might have much

Re: [PATCH v2] drivers/block/loop: Replace deprecated function in option parsing code

2019-06-25 Thread Chaitanya Kulkarni
I believe you have tested this patch with loop testcases present in the :- https://github.com/osandov/blktests/tree/master/tests/loop. With that, looks good. Reviewed-by: Chaitanya Kulkarni . On 06/25/2019 10:55 AM, Florian Knauf wrote: > This patch removes the deprecated simple_strtol function

[PATCH v2] drivers/block/loop: Replace deprecated function in option parsing code

2019-06-25 Thread Florian Knauf
This patch removes the deprecated simple_strtol function from the option parsing logic in the loopback device driver. Instead kstrtoint is used to parse int max_loop, to ensure that input values it cannot represent are ignored. Signed-off-by: Florian Knauf Signed-off-by: Christian Ewert --- Than

Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Christoph Hellwig
On Tue, Jun 25, 2019 at 09:57:52AM -0600, Logan Gunthorpe wrote: > > You assume all addressing is done by the PCI bus address. If a device > > is addressing its own BAR there is no reason to use the PCI bus address, > > as it might have much more intelligent schemes (usually bar + offset). > > Ye

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Christoph Hellwig
On Tue, Jun 25, 2019 at 11:46:23AM +0900, Damien Le Moal wrote: > To allow the SCSI subsystem scsi_execute_req() function to issue > requests using large buffers that are better allocated with vmalloc() > rather than kmalloc(), modify bio_map_kern() to allow passing a buffer > allocated with the vm

Re: [PATCH 3/3] block: Limit zone array allocation size

2019-06-25 Thread Bart Van Assche
On 6/24/19 7:46 PM, Damien Le Moal wrote: Limit the size of the struct blk_zone array used in blk_revalidate_disk_zones() to avoid memory allocation failures leading to disk revalidation failure. Further reduce the likelyhood of these failures by using kvmalloc() instead of directly allocating co

Re: [PATCH 2/3] sd_zbc: Fix report zones buffer allocation

2019-06-25 Thread Bart Van Assche
On 6/24/19 7:46 PM, Damien Le Moal wrote: During disk scan and revalidation done with sd_revalidate(), the zones of a zoned disk are checked using the helper function blk_revalidate_disk_zones() if a configuration change is detected (change in the number of zones or zone size). The function blk_r

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Chaitanya Kulkarni
On 06/25/2019 08:59 AM, Bart Van Assche wrote: > On 6/24/19 8:24 PM, Chaitanya Kulkarni wrote: >> nit:- Can we use is_vmalloc_addr() call directly so that >> "if (is_vmalloc)" -> "if (is_vmalloc_addr(data))" and remove is_vmalloc >> variable. > That would change a single call of is_vmalloc_addr()

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Bart Van Assche
On 6/24/19 7:46 PM, Damien Le Moal wrote: To allow the SCSI subsystem scsi_execute_req() function to issue requests using large buffers that are better allocated with vmalloc() rather than kmalloc(), modify bio_map_kern() to allow passing a buffer allocated with the vmalloc() function. To do so,

Re: [PATCH 1/3] block: Allow mapping of vmalloc-ed buffers

2019-06-25 Thread Bart Van Assche
On 6/24/19 8:24 PM, Chaitanya Kulkarni wrote: nit:- Can we use is_vmalloc_addr() call directly so that "if (is_vmalloc)" -> "if (is_vmalloc_addr(data))" and remove is_vmalloc variable. That would change a single call of is_vmalloc_addr() into multiple? Bart.

Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Logan Gunthorpe
On 2019-06-25 1:20 a.m., Christoph Hellwig wrote: > On Mon, Jun 24, 2019 at 10:07:56AM -0600, Logan Gunthorpe wrote: >>> For one passing a dma_addr_t through the block layer is a layering >>> violation, and one that I think will also bite us in practice. >>> The host physical to PCIe bus address

Re: [PATCH] drivers/block/loop: Remove deprecated function, range check for max_loop

2019-06-25 Thread Chaitanya Kulkarni
Thanks for your patch. On 06/25/2019 04:47 AM, Florian Knauf wrote: > This patch removes the deprecated simple_strtol function from the option > parsing logic in the loopback device driver. It also introduces a range > check for the max_loop parameter to ensure that negative and out-of-range > val

Re: [PATCH BUGFIX IMPROVEMENT V2 0/7] boost throughput with synced I/O, reduce latency and fix a bandwidth bug

2019-06-25 Thread Jens Axboe
On 6/24/19 11:12 PM, Paolo Valente wrote: > [SAME AS V1, APART FROM SRIVATSA ADDED AS REPORTER] > > Hi Jens, > this series, based against for-5.3/block, contains: > 1) The improvements to recover the throughput loss reported by > Srivatsa [1] (first five patches) > 2) A preemption improvement

Re: [PATCH v3 5/5] nvme: add support weighted round robin queue

2019-06-25 Thread Weiping Zhang
Minwoo Im 于2019年6月25日周二 上午6:01写道: > > > @@ -2627,7 +2752,30 @@ static int nvme_pci_get_address(struct nvme_ctrl > > *ctrl, char *buf, int size) > > > > static void nvme_pci_get_ams(struct nvme_ctrl *ctrl, u32 *ams) > > { > > - *ams = NVME_CC_AMS_RR; > > + /* if deivce doesn't support WR

Re: [PATCH v3 4/5] genirq/affinity: allow driver's discontigous affinity set

2019-06-25 Thread Weiping Zhang
Thomas Gleixner 于2019年6月25日周二 下午3:36写道: > > MIng, > > On Tue, 25 Jun 2019, Ming Lei wrote: > > On Mon, Jun 24, 2019 at 05:42:39PM +0200, Thomas Gleixner wrote: > > > On Mon, 24 Jun 2019, Weiping Zhang wrote: > > > > > > > The driver may implement multiple affinity set, and some of > > > > are empt

Re: [PATCH v3 3/5] nvme-pci: rename module parameter write_queues to read_queues

2019-06-25 Thread Weiping Zhang
Minwoo Im 于2019年6月25日周二 上午6:00写道: > > On 19-06-24 22:29:19, Weiping Zhang wrote: > > Now nvme support three type hardware queues, read, poll and default, > > this patch rename write_queues to read_queues to set the number of > > read queues more explicitly. This patch alos is prepared for nvme > >

Re: [PATCH v3 2/5] nvme: add get_ams for nvme_ctrl_ops

2019-06-25 Thread Weiping Zhang
Minwoo Im 于2019年6月25日周二 上午6:01写道: > > On 19-06-24 22:29:05, Weiping Zhang wrote: > > The get_ams() will return the AMS(Arbitration Mechanism Selected) > > from the driver. > > > > Signed-off-by: Weiping Zhang > > Hello, Weiping. > > Sorry, but I don't really get what your point is here. Could yo

[PATCH] drivers/block/loop: Remove deprecated function, range check for max_loop

2019-06-25 Thread Florian Knauf
This patch removes the deprecated simple_strtol function from the option parsing logic in the loopback device driver. It also introduces a range check for the max_loop parameter to ensure that negative and out-of-range values (that cannot be represented by int max_loop) are ignored. Signed-off-by:

Re: [PATCH 2/3] sd_zbc: Fix report zones buffer allocation

2019-06-25 Thread kbuild test robot
/commits/Damien-Le-Moal/Fix-zone-revalidation-memory-allocation-failures/20190625-175053 base: https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git for-next config: sparc64-allyesconfig (attached as .config) compiler: sparc64-linux-gcc (GCC) 7.4.0 reproduce: wget https

Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Christoph Hellwig
On Mon, Jun 24, 2019 at 10:07:56AM -0600, Logan Gunthorpe wrote: > > For one passing a dma_addr_t through the block layer is a layering > > violation, and one that I think will also bite us in practice. > > The host physical to PCIe bus address mapping can have offsets, and > > those offsets absolu

Re: [RFC PATCH 00/28] Removing struct page from P2PDMA

2019-06-25 Thread Christoph Hellwig
On Mon, Jun 24, 2019 at 10:10:16AM -0600, Logan Gunthorpe wrote: > Yes, that's correct. The intent was to invert it so the dma_map could > happen at the start of the process so that P2PDMA code could be called > with all the information it needs to make it's decision on how to map; > without having