]> www.infradead.org Git - users/dwmw2/linux.git/commit
orangefs: make open_for_read and open_for_write boolean
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Wed, 5 Mar 2025 20:47:27 +0000 (20:47 +0000)
committerChristian Brauner <brauner@kernel.org>
Thu, 6 Mar 2025 08:26:06 +0000 (09:26 +0100)
commit144fa8ae0830280a1d9b53e80f55b8c51260a4ab
tree8623d3cf840f59377fa78cb1d757605a39e87f4e
parent50fb0a7f43c0ada5414a6d3e3f49e2109693c06c
orangefs: make open_for_read and open_for_write boolean

sparse currently warns:

fs/orangefs/file.c:119:32: warning: incorrect type in assignment (different base types)
fs/orangefs/file.c:119:32:    expected int open_for_write
fs/orangefs/file.c:119:32:    got restricted fmode_t

Turning open_for_write and open_for_read into booleans (which is how
they're used) removes this warning.

Signed-off-by: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Link: https://lore.kernel.org/r/20250305204734.1475264-4-willy@infradead.org
Tested-by: Mike Marshall <hubcap@omnibond.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/orangefs/file.c