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
| ||
|
Date: Thu, 11 Jun 2020 17:24:30 -0600 From: Logan Gunthorpe <logang@...tatee.com> To: Chaitanya Kulkarni <Chaitanya.Kulkarni@....com>, "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>, "linux-nvme@...ts.infradead.org" <linux-nvme@...ts.infradead.org> Cc: Christoph Hellwig <hch@....de>, Sagi Grimberg <sagi@...mberg.me>, Keith Busch <kbusch@...nel.org>, Jens Axboe <axboe@...com>, Max Gurtovoy <maxg@...lanox.com>, Stephen Bates <sbates@...thlin.com> Subject: Re: [PATCH v13 8/9] nvmet-passthru: Add enable/disable helpers On 2020-06-11 5:13 p.m., Chaitanya Kulkarni wrote: > On 5/14/20 10:23 AM, Logan Gunthorpe wrote: >> + if (subsys->ver < NVME_VS(1, 2, 1)) { >> + pr_warn("nvme controller version is too old: %d.%d.%d, advertising 1.2.1\n", > Is it more than 80 char ? can it be ? > pr_warn("nvme controller version is too old: "); > pr_warn("%d.%d.%d, advertising 1.2.1\n", Splitting printks is a bad idea because they won't necessarily end up in dmesg right next to each other -- other prints can be interleaved. Moreover, it breaks any tools that are dealing with kernel logs as single records (ie through /dev/kmsg). Continuations (or printks without a trailing "\n") would require using pr_cont() and generally that's discouraged. >> + (int)NVME_MAJOR(subsys->ver), >> + (int)NVME_MINOR(subsys->ver), >> + (int)NVME_TERTIARY(subsys->ver)); >> + subsys->ver = NVME_VS(1, 2, 1); >> + } > > NVMe blktests are running on QEMU based controller. This will generate > warning every-time. Yup. > Also, I didn't understand int type cast, I wonder under what condition > all these macros will return -ve values since ver of type u64 ? Yes, I'm not sure what I was thinking when I put in the cast. Probably better just to prints "%llu". I'll fix this for the next revision. Thanks, Logan
Powered by blists - more mailing lists