Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp3714179ybv; Mon, 10 Feb 2020 05:11:17 -0800 (PST) X-Google-Smtp-Source: APXvYqwX6NTNVyV9bVm3UJc/481MywW+LJlUVUFf7jdb1p5ICXYDOkFxUCVCBV9/NKjPOUMuKkYt X-Received: by 2002:a05:6808:346:: with SMTP id j6mr792652oie.47.1581340277607; Mon, 10 Feb 2020 05:11:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581340277; cv=none; d=google.com; s=arc-20160816; b=s43GW5ztSbAqJYkI5yZHtd2+ji4ybcn0E14VEyu+wJkcbW8FEyVRtmi0xtPKuL1EEW 2wc4l0OIA896nTjugDj17AeMR7JIRpPB4n01m2FHUhvIj3zbjhXuf2y96Y5iyxPw5+hs 62HgKEBrIWKwxsJPmP5IM+rhA/LT0AB7kNe/tLwHrvT+Cmp63BDQzHEhW3xZvR2TKsAp pSOZc3Heq9PTevqFnbjUbswMGi1iDJy2/d/p8GqtDiuz0yxyd55CcYsNoDiAXI5Wk7K4 YhYoGoDdiHqsPgw37aFAznj0vKO1liUEWI+IMd1+3DQcc7vJqasfTUvDZPW2fi3q6dOR YZjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=kwC4h/EMFmusntKH8xzjhCeBUOMTE0cFgc2VrNo5WMo=; b=PJW2T64gYQgNB28OQlGHEUdQWk8jeINwLg1kBQ3hgbtKi9mbRAZiQQLqzdzx0mdSvH cACy5V5GYB2DsrZMcXh6d5DemLk8LZhRkHHJyIKB59rbNZTbE0GZIeRda5QNsXXxpFCZ OjXv6jHn0uYqx4FymbjYRXXDExsJIua9NJ6T26tdIt/B09nwqJr2GhE0J/VaQkGVitCU rKT/n0GZH3EW0nB6HDosYt26N2Y/T+nfcdrdZXltYu8ZSUkLLu7FgdA/3sVNs852rpAp acNVNVrhFoSkM5jSYydoecgj4WDWEKXUEYwNko4UUETlW3IJR1+LrzhsyDp4l7maKh// Cj6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=TUGElK8j; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x26si150071otk.325.2020.02.10.05.11.05; Mon, 10 Feb 2020 05:11:17 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=TUGElK8j; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729553AbgBJNKC (ORCPT + 99 others); Mon, 10 Feb 2020 08:10:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:36236 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729368AbgBJMjO (ORCPT ); Mon, 10 Feb 2020 07:39:14 -0500 Received: from localhost (unknown [209.37.97.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2BD4F21739; Mon, 10 Feb 2020 12:39:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581338354; bh=wovP3Mj7Cc3GvATp2zQxzdlvx6+rxd/8fCceQK2SHRs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=TUGElK8jq3ggOTO5QxHD3kphCkb7U72IfOYrssS/ndVraDbz9zJ1SzWn9qlnuKMNA /ITgmPrqMF2MnnBuFHKN8EDN5OUPBEXzUXIrXN3HgP6Prqgkf/fnDO5LAXstN08VkL wSe5a/IF4VcAmbgIGHBDTzRLA0uyVkWkNroEqBbs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sam Ravnborg , "Dmitry V . Levin" , Rich Felker , libc-alpha@sourceware.org, Arnd Bergmann , "David S. Miller" Subject: [PATCH 5.5 001/367] [PATCH] sparc32: fix struct ipc64_perm type definition Date: Mon, 10 Feb 2020 04:28:34 -0800 Message-Id: <20200210122423.883447269@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200210122423.695146547@linuxfoundation.org> References: <20200210122423.695146547@linuxfoundation.org> User-Agent: quilt/0.66 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnd Bergmann [ Upstream commit 34ca70ef7d3a9fa7e89151597db5e37ae1d429b4 ] As discussed in the strace issue tracker, it appears that the sparc32 sysvipc support has been broken for the past 11 years. It was however working in compat mode, which is how it must have escaped most of the regular testing. The problem is that a cleanup patch inadvertently changed the uid/gid fields in struct ipc64_perm from 32-bit types to 16-bit types in uapi headers. Both glibc and uclibc-ng still use the original types, so they should work fine with compat mode, but not natively. Change the definitions to use __kernel_uid32_t and __kernel_gid32_t again. Fixes: 83c86984bff2 ("sparc: unify ipcbuf.h") Link: https://github.com/strace/strace/issues/116 Cc: # v2.6.29 Cc: Sam Ravnborg Cc: "Dmitry V . Levin" Cc: Rich Felker Cc: libc-alpha@sourceware.org Signed-off-by: Arnd Bergmann Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- arch/sparc/include/uapi/asm/ipcbuf.h | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) --- a/arch/sparc/include/uapi/asm/ipcbuf.h +++ b/arch/sparc/include/uapi/asm/ipcbuf.h @@ -17,19 +17,19 @@ struct ipc64_perm { - __kernel_key_t key; - __kernel_uid_t uid; - __kernel_gid_t gid; - __kernel_uid_t cuid; - __kernel_gid_t cgid; + __kernel_key_t key; + __kernel_uid32_t uid; + __kernel_gid32_t gid; + __kernel_uid32_t cuid; + __kernel_gid32_t cgid; #ifndef __arch64__ - unsigned short __pad0; + unsigned short __pad0; #endif - __kernel_mode_t mode; - unsigned short __pad1; - unsigned short seq; - unsigned long long __unused1; - unsigned long long __unused2; + __kernel_mode_t mode; + unsigned short __pad1; + unsigned short seq; + unsigned long long __unused1; + unsigned long long __unused2; }; #endif /* __SPARC_IPCBUF_H */