summaryrefslogtreecommitdiff
path: root/net/unix/af_unix.c
diff options
context:
space:
mode:
authorSebastian Reichel <sebastian.reichel@collabora.com>2025-07-07 01:53:35 +0300
committerSebastian Reichel <sebastian.reichel@collabora.com>2025-07-07 01:53:35 +0300
commit61b8c39deb4b6d314f942a4a33565575c9b0c3d5 (patch)
treef25268cdd9485af13d9efa05db3d88754a82f82b /net/unix/af_unix.c
parentd375b70a0f47a032813be33493c97133cc080f74 (diff)
parentcd4da713f99651e99fbce8ed6b6ec8f686c029a8 (diff)
downloadlinux-61b8c39deb4b6d314f942a4a33565575c9b0c3d5.tar.xz
Merge tag 'pm-runtime-6.17-rc1'
Runtime PM updates related to autosuspend for 6.17 Make several autosuspend functions mark last busy stamp and update the documentation accordingly (Sakari Ailus). Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'net/unix/af_unix.c')
-rw-r--r--net/unix/af_unix.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c
index 2e2e9997a68e..22e170fb5dda 100644
--- a/net/unix/af_unix.c
+++ b/net/unix/af_unix.c
@@ -1971,7 +1971,8 @@ static void unix_maybe_add_creds(struct sk_buff *skb, const struct sock *sk,
if (UNIXCB(skb).pid)
return;
- if (unix_may_passcred(sk) || unix_may_passcred(other)) {
+ if (unix_may_passcred(sk) || unix_may_passcred(other) ||
+ !other->sk_socket) {
UNIXCB(skb).pid = get_pid(task_tgid(current));
current_uid_gid(&UNIXCB(skb).uid, &UNIXCB(skb).gid);
}