Commit 9bedee7
af_unix: rework unix_maybe_add_creds() to allow sleep
As a preparation for the next patches we need to allow sleeping
in unix_maybe_add_creds() and also return err. Currently, we can't do
that as unix_maybe_add_creds() is being called under unix_state_lock().
There is no need for this, really. So let's move call sites of
this helper a bit and do necessary function signature changes.
Cc: linux-kernel@vger.kernel.org
Cc: netdev@vger.kernel.org
Cc: David S. Miller <davem@davemloft.net>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Paolo Abeni <pabeni@redhat.com>
Cc: Simon Horman <horms@kernel.org>
Cc: Leon Romanovsky <leon@kernel.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Christian Brauner <brauner@kernel.org>
Cc: Kuniyuki Iwashima <kuniyu@google.com>
Cc: Lennart Poettering <mzxreary@0pointer.de>
Cc: Luca Boccassi <bluca@debian.org>
Cc: David Rheinsberg <david@readahead.eu>
Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>
Link: https://lore.kernel.org/20250703222314.309967-2-aleksandr.mikhalitsyn@canonical.com
Reviewed-by: Christian Brauner <brauner@kernel.org>
Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>1 parent 8676730 commit 9bedee7
1 file changed
Lines changed: 25 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1955 | 1955 | | |
1956 | 1956 | | |
1957 | 1957 | | |
1958 | | - | |
| 1958 | + | |
| 1959 | + | |
| 1960 | + | |
| 1961 | + | |
| 1962 | + | |
| 1963 | + | |
1959 | 1964 | | |
1960 | 1965 | | |
1961 | 1966 | | |
| 1967 | + | |
| 1968 | + | |
1962 | 1969 | | |
1963 | | - | |
1964 | | - | |
| 1970 | + | |
| 1971 | + | |
1965 | 1972 | | |
1966 | 1973 | | |
1967 | | - | |
| 1974 | + | |
1968 | 1975 | | |
1969 | 1976 | | |
1970 | 1977 | | |
1971 | 1978 | | |
1972 | 1979 | | |
| 1980 | + | |
| 1981 | + | |
1973 | 1982 | | |
1974 | 1983 | | |
1975 | 1984 | | |
| |||
2104 | 2113 | | |
2105 | 2114 | | |
2106 | 2115 | | |
| 2116 | + | |
| 2117 | + | |
| 2118 | + | |
| 2119 | + | |
2107 | 2120 | | |
2108 | 2121 | | |
2109 | 2122 | | |
| |||
2212 | 2225 | | |
2213 | 2226 | | |
2214 | 2227 | | |
2215 | | - | |
2216 | 2228 | | |
2217 | 2229 | | |
2218 | 2230 | | |
| |||
2256 | 2268 | | |
2257 | 2269 | | |
2258 | 2270 | | |
| 2271 | + | |
| 2272 | + | |
| 2273 | + | |
| 2274 | + | |
2259 | 2275 | | |
2260 | 2276 | | |
2261 | 2277 | | |
| |||
2275 | 2291 | | |
2276 | 2292 | | |
2277 | 2293 | | |
2278 | | - | |
2279 | 2294 | | |
2280 | 2295 | | |
2281 | 2296 | | |
| |||
2369 | 2384 | | |
2370 | 2385 | | |
2371 | 2386 | | |
| 2387 | + | |
| 2388 | + | |
| 2389 | + | |
| 2390 | + | |
2372 | 2391 | | |
2373 | 2392 | | |
2374 | 2393 | | |
| |||
2399 | 2418 | | |
2400 | 2419 | | |
2401 | 2420 | | |
2402 | | - | |
2403 | 2421 | | |
2404 | 2422 | | |
2405 | 2423 | | |
| |||
0 commit comments