lkml.org 
[lkml]   [2021]   [Jun]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] docs: fault-injection: fix non-working usage of negative values

Yeah, I also assume that it used to work at some time. Didn't bother to
investigate, though.

> The code uses debugfs_create_atomic_t(), and atomic_t is signed, so
> I'd expect negative numbers to work.

In debugfs, it is all cast from unsigned long long to something. Check
simple_attr_write() where the value is obtained with kstrtoull. The code
fix would be to not use simple_attr, I think. I opted for the doc fix.

[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2021-06-03 17:36    [W:0.045 / U:1.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site