Re: [PATCH V2 1/1] mdadm/Grow: Update new level when starting reshape

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

 



On Wed, 11 Sep 2024 16:54:23 +0800
Xiao Ni <xni@xxxxxxxxxx> wrote:

> +
> +		/* new_level is introduced in kernel 6.12 */
> +		if (!err && get_linux_version() >= 6012000 &&
> +				sysfs_set_num(sra, NULL, "new_level",
> info->new_level) < 0)
> +			err = errno;

Hi Xiao,
I realized that we would do this better by checking existence of new_level
sysfs file. This way, our solution is limited to kernel > 6.12 so, for example
redhat 9 with kernel 5.14 will never pass the condition. I know that you fixed
test issue but someone still may find this in real life.

I'm not going to rework it myself, I'm fine with current approach until
someone will report issue about that for older kernel.

If you are going to rework this, please left a comment about kernel version
that it was added, to let future maintainers know when the additional
verification can be removed.

Thanks,
Mariusz




[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux