** Also affects: zfs-linux (Ubuntu Impish)
   Importance: Medium
     Assignee: Colin Ian King (colin-king)
       Status: In Progress

** Also affects: zfs-linux (Ubuntu Hirsute)
   Importance: Undecided
       Status: New

** Changed in: zfs-linux (Ubuntu Hirsute)
     Assignee: (unassigned) => Colin Ian King (colin-king)

** Changed in: zfs-linux (Ubuntu Hirsute)
       Status: New => In Progress

** Changed in: zfs-linux (Ubuntu Hirsute)
   Importance: Undecided => Medium

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to zfs-linux in Ubuntu.
https://bugs.launchpad.net/bugs/1942991

Title:
  zfs: can't read /proc/sys/kernel/spl/hostid

Status in zfs-linux package in Ubuntu:
  In Progress
Status in zfs-linux source package in Hirsute:
  In Progress
Status in zfs-linux source package in Impish:
  In Progress

Bug description:
  Reading  /proc/sys/kernel/spl/hostid no longer works in 5.7+ kernels
  upwards.

  The Fix:

  commit 7de4c88b39473f358add601e8c227ca9002b1bee
  Author: наб <nabijaczlew...@nabijaczleweli.xyz>
  Date:   Sun Apr 11 01:18:40 2021 +0200

      linux/spl: base proc_dohostid() on proc_dostring()
      
      This fixes /proc/sys/kernel/spl/hostid on kernels with mainline commit
      32927393dc1ccd60fb2bdc05b9e8e88753761469 ("sysctl: pass kernel pointers
      to ->proc_handler") ‒ 5.7-rc1 and up
      
      The access_ok() check in copy_to_user() in proc_copyout_string() would
      always fail, so all userspace reads and writes would fail with EINVAL
      
      proc_dostring() strips only the final new-line,
      but simple_strtoul() doesn't actually need a back-trimmed string ‒
      writing "012345678   \n" is still allowed, as is "012345678zupsko", &c.
      
      This alters what happens when an invalid value is written ‒
      previously it'd get set to what-ever simple_strtoul() returned
      (probably 0, thereby resetting it to default), now it does nothing
      
      Reviewed-by: Brian Behlendorf <behlendo...@llnl.gov>
      Signed-off-by: Ahelenia Ziemiańska <nabijaczlew...@nabijaczleweli.xyz>
      Closes #11878
      Closes #11879

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1942991/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to