lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20210715225049.66252-1-miquel.raynal@bootlin.com>
Date:   Fri, 16 Jul 2021 00:50:49 +0200
From:   Miquel Raynal <miquel.raynal@...tlin.com>
To:     Zhihao Cheng <chengzhihao1@...wei.com>, miquel.raynal@...tlin.com,
        richard@....at, vigneshr@...com
Cc:     linux-mtd@...ts.infradead.org, linux-kernel@...r.kernel.org,
        yukuai3@...wei.com
Subject: Re: [PATCH v2] mtd: mtd_blkdevs: Initialize rq.limits.discard_granularity

On Tue, 2021-06-15 at 09:39:05 UTC, Zhihao Cheng wrote:
> Since commit b35fd7422c2f8("block: check queue's limits.discard_granularity
> in __blkdev_issue_discard()") checks rq.limits.discard_granularity in
> __blkdev_issue_discard(), we may get following warnings on formatted ftl:
> 
>   WARNING: CPU: 2 PID: 7313 at block/blk-lib.c:51
>   __blkdev_issue_discard+0x2a7/0x390
> 
> Reproducer:
>   1. ftl_format /dev/mtd0
>   2. modprobe ftl
>   3. mkfs.vfat /dev/ftla
>   4. mount -odiscard /dev/ftla temp
>   5. dd if=/dev/zero of=temp/tst bs=1M count=10 oflag=direct
>   6. dd if=/dev/zero of=temp/tst bs=1M count=10 oflag=direct
> 
> Fix it by initializing rq.limits.discard_granularity if device supports
> discard operation.
> 
> Signed-off-by: Zhihao Cheng <chengzhihao1@...wei.com>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/fixes, thanks.

Miquel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ