Re: [PATCH 10/12] badblocks: return boolen from badblocks_set() and badblocks_clear()

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

 



Dear Zheng,


Thank you for your patch. *boolean* in the summary/title is missing an *a*.

Am 22.02.25 um 02:26 schrieb Yu Kuai:

Just two simple coding styes below.

I’d put these into a separate commit.

在 2025/02/21 16:11, Zheng Qixing 写道:
From: Zheng Qixing <zhengqixing@xxxxxxxxxx>

Change the return type of badblocks_set() and badblocks_clear()
from int to bool, indicating success or failure. Specifically:

- _badblocks_set() and _badblocks_clear() functions now return
true for success and false for failure.
- All calls to these functions have been updated to handle the
new boolean return type.

I’d use present tense: are updated

- This change improves code clarity and ensures a more consistent
handling of success and failure states.

Signed-off-by: Zheng Qixing <zhengqixing@xxxxxxxxxx>
---
  block/badblocks.c             | 37 +++++++++++++++++------------------
  drivers/block/null_blk/main.c | 17 ++++++++--------
  drivers/md/md.c               | 35 +++++++++++++++++----------------
  drivers/nvdimm/badrange.c     |  2 +-
  include/linux/badblocks.h     |  6 +++---
  5 files changed, 49 insertions(+), 48 deletions(-)

[…]


Kind regards,

Paul




[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