Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753178AbdHBRa0 (ORCPT ); Wed, 2 Aug 2017 13:30:26 -0400 Received: from mail-dm3nam03on0053.outbound.protection.outlook.com ([104.47.41.53]:64810 "EHLO NAM03-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753137AbdHBRaV (ORCPT ); Wed, 2 Aug 2017 13:30:21 -0400 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Yuri.Norov@cavium.com; Date: Wed, 2 Aug 2017 20:29:40 +0300 From: Yury Norov To: Catalin Marinas Cc: Pratyush Anand , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH RFC] arm64: introduce mm_context_t flags Message-ID: <20170802172940.ejiyl4j2ywlwhbme@yury-thinkpad> References: <20170731144825.31322-1-ynorov@caviumnetworks.com> <20170802163900.66gnhogililb3uak@armageddon.cambridge.arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170802163900.66gnhogililb3uak@armageddon.cambridge.arm.com> User-Agent: NeoMutt/20170113 (1.7.2) X-Originating-IP: [105.158.109.91] X-ClientProxiedBy: HE1PR09CA0085.eurprd09.prod.outlook.com (10.174.50.157) To CY1PR07MB2120.namprd07.prod.outlook.com (10.164.73.158) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5ffbfa76-29aa-47ae-5de6-08d4d9cc2531 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:CY1PR07MB2120; X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2120;3:eHFxuhJKRX8mqrd8iuUSEmTaOT3CIpL8xT3oS3Cx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4rVlguDYqB3ROTdMvvLL8E7EB6V1gPja1QB4j52xC23TzxZuMQr6gYthuEd+XnG06iwdlAIk647J98hFILfvZBmVAeucMD4u00yaLgWozaC3L8bzeSpKra7VC3k6bcknGQUbLesgbKSIf1OFNgpmvjPBDf2BjKaEU0QBeEYzakrRL3jwtHr2IicrcqYY6tkdmdanUDbruvrZ6kxkPHmhzV+LdvnU7/X/1Aip197GkefIGnXg9GthO8N/Ox1hQBpWctPwFmWoHpSB788aJbQGfb7qr2w/U5H72bdWEggwfNseNhqqegJhp1MsL9GVm11ltWAYBLp+28b3LwEmAe8IHjJDVKHM0lv7xd34IZitnDy/qmhFcBt5cpfa X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2120;20:r9GSQFYox9y3Jl1Y3Y0Dbcr/evvTBGpq4w9IqZa6EORLWhqw6w5OQl8hMp9+iJ4qSQXgt9DTJnkk2Lj7ldNd/maxDbD61ZY+cv+RfCJr9RyGsxzxPxrIsxv3VUJe5COcNRDY/Md3/qxWpiwlA6Eq0LT/AAJfHHSl14KNWUoogEpjqXQML3JtLxmn28bw1xHpwYbrSWs716njSxLJDZ59loMFP4LyaWlXCdXeyRFKGQwHNsXrdY6KEMPaKjNzPqw08nzhDhSXSNOfWujUpCASK4UqCIeQlOwb5rpTFmPvWpQ1l6Ysit/kKfNzlZa70Ptto5bPwzJbppjTzyrZT2+SmoxWBxKGbLTbqzycReOyThW5ZSFk8q7/VndryZ7InKDLXW0hKhClmYavuX8rx4CXsBdhtoaXVSqcWqHsxEVDybsChbouY+Xc53ngU/GDAwGfDRn7FMMx80e+c0/HyodMfyaNZK4pLCROxWP4N7vxvrfQdoJnDrRB46d+CKFdfTSOxXLI8C1ddOWHR6TGIvNfTlhkzMFc9W9Af+JFHShcb2vohRLiL/NMEKFVlVClnCtHhfBGp46oJ+Jz1qqh349maetQkRYzfLY8s5MmOOMwiy0= X-Exchange-Antispam-Report-Test: UriScan:(278428928389397); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(100000703101)(100105400095)(93006095)(10201501046)(3002001)(6041248)(20161123555025)(20161123562025)(20161123564025)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:CY1PR07MB2120;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:CY1PR07MB2120; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CY1PR07MB2120;4:d9gKgrol++dldhvohkH6+KhJkcw+o+4jKfyuBIWwlR?= =?us-ascii?Q?Y8jDpjQJfwsh5kLzbLRICmUTBGppAXh4HvjpPMW4E15uAPEVViIK8Qr1ubUq?= =?us-ascii?Q?s7G3D7PwM111TThfExmpiu1DQCKlxn3CxAjuoVnt6cQYWIvQ8bfB4NMD0roP?= =?us-ascii?Q?sgNX/rMxCsSBHooXmkJdoZjfdaasCeu/MGetRyPa7nnojj1uoiIZuw2Kx8qf?= =?us-ascii?Q?lr6FjvnMHQxbJtObDL5+TucQt8eODs8mNcZd/pvc0K/PzNFSdRx4d+ghxY6E?= =?us-ascii?Q?uupAdKAj6HkdEK6LEZx3GZjrkT7rB0oHWNtG/qD7hNnIsgk16oor1EGeOOsX?= =?us-ascii?Q?oa8h0Lv4iaHWVQOXyzuS0FYdmm/JtARz31al1doJ54LIllx9ndNheaa7PhnY?= =?us-ascii?Q?KNi9ptPaV5Zomkwc4Rk05I2poI0NzgE5ZcExtcba4uzHQpLKNsv43L9jFWVf?= =?us-ascii?Q?n5vcBbfS4B/9ockreHGEhgsNIcp5DdEFQWJLmWrNZpKdAib6baOOiDu5ehWw?= =?us-ascii?Q?h9ib8J+zjUFk466x9wBBNhmQCCWN5jldktIvJIPZCbkU0GqMTiyrAUZRpfSl?= =?us-ascii?Q?8mbPm9N08Ujs3b+32eKn5l18OspO0H3ossuh4zc4dRW3DsBg9ah7QTuqPyVL?= =?us-ascii?Q?Wf9eVyKS7t+dfGas9c+VNgk7+7KmwlxGBoSXuwtBeCMlivz4KGs4DTB8qr/m?= =?us-ascii?Q?SU9EEhAZGdsHfAP/687phlclruejL9T4KSyeB1oMIR8+sp9x+b/1yojQwbek?= =?us-ascii?Q?vvZarUYco7VN6kq8C0EEnh7qKA2BLwbMoWGdnhNFimyT+g1wvKkvUAnoDoeL?= =?us-ascii?Q?uFNUqhxGsnJaV5IpybNIsVKA8+DXB+amLiB9ia/UExn4Iva8j29QbAAvSBC3?= =?us-ascii?Q?5b9+3ekQy2j5uSTqT7hL+9MtvIp5nhfvpSVlTaEOy9RRxWd0Ggo6wmJUuUCb?= =?us-ascii?Q?vE7a4dsQ5Ewc1EIjMdP0riwsryzyA+fq0fC/eYsi6lS5V2crvo2lC/EarpnH?= =?us-ascii?Q?yii8iwYMsri17T39y/oUBr7tKWofF2s8fimnMKGxPMstlU/ToamSxKx/zVYG?= =?us-ascii?Q?NDDegWnPBtSbo8N4nPfJIKXSFr6DFFGJoaUmoUrwgDXcPgdwORQMSu9bHq+X?= =?us-ascii?Q?Km426d9IFdZUSvm7MUOA28aY7U0/I14XK6HcyWVqOdgfL/f/f4ng=3D=3D?= X-Forefront-PRVS: 0387D64A71 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(7370300001)(4630300001)(6069001)(6009001)(39410400002)(39850400002)(39840400002)(39400400002)(39450400003)(24454002)(199003)(51444003)(189002)(4326008)(189998001)(76506005)(68736007)(25786009)(97736004)(229853002)(1076002)(53936002)(50466002)(2906002)(72206003)(50986999)(105586002)(47776003)(101416001)(478600001)(42186005)(5660300001)(54356999)(33716001)(76176999)(66066001)(6666003)(7350300001)(2950100002)(6916009)(42882006)(4001350100001)(23726003)(6116002)(106356001)(3846002)(83506001)(8676002)(110136004)(38730400002)(33646002)(81166006)(81156014)(6486002)(6246003)(6496005)(305945005)(9686003)(7736002);DIR:OUT;SFP:1101;SCL:1;SRVR:CY1PR07MB2120;H:localhost;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CY1PR07MB2120;23:JF0VYRmIdTgJjnbzDV92vdEFvhwm3jB5FWAbHiG0z?= =?us-ascii?Q?aR0ipffZIGa+ivZk10pEo8BhfyG1TpyvBDtUtJxfkTjiLTPX0sOI7G2QDDhg?= =?us-ascii?Q?NEpZWa+YG5O1QT6dl2vuu5XwH+rihUzGyf0BxQ9d/qXVQRaaCMc/iaVDq5WO?= =?us-ascii?Q?pYSt0rPfyW7gg9SZRKXp8b5rw9Az9G0ypc5867WBxDuTv+2plHzpbxO/c6z7?= =?us-ascii?Q?2yZ8k0eDwiF0A01zhBuQLU42vXj3KTHbJbVHVeS1A1lJplEGii1bwxvZv/qR?= =?us-ascii?Q?gpv8dWy99IRJ5zYiIULKUHyCYnTDk0qeVIXxu5y5sTBVYNs8MYT93+zezQz7?= =?us-ascii?Q?YqWHw5UoVBZVhjTlgKx9/G2m0tmSvboRIR7tWc4Mx7LvBe8veUJsf14lNeCp?= =?us-ascii?Q?stsE6a1M0zgIxyvtIKrdP+rob5XsGia5APrC56cRYVZdknaYu6Ne/2MrgVl7?= =?us-ascii?Q?fQUjuvn90e4/T7beDN15Gnc/euMX67FAbmLDwDGecz5zUQpLNwlUanGKZ+9o?= =?us-ascii?Q?qRuJZx2rR+HbCqWYo8jc/VmKCWC7AcoaT1iALVxAcR/MwL/gxEFHGADenEOB?= =?us-ascii?Q?VGumJ33vK8KZrapHi/6WL9C/PAGMgBLJhAz1HUrTPiNSj+9mW6iyE2L143m5?= =?us-ascii?Q?vsFPHHkZTLid2hZdjViIZOW+PFwcjoUgFQ+y75jMFmwiFMF91aT1VpwyJtXL?= =?us-ascii?Q?B3tU/zTPqbq0hzbIB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7TeoTIOAzIUhenDtqeXnySozSVmT8urE7HyYq9GPnVHyh9fLIiJMLLAH7MQK1JITeXvEstr/0yg33uRu9UEE3rz1TH60/3MrLCAfZMVDxPC51cx+xwME70izM+mTzyMkUXtZLNPnRaeEoZ9ubMRTK+XRmcWCN+9OrwN7gbEiZcguEelXeYF8dA0ZhT9dSlaUaptmMMPCntaUYsjPNEEfn4F5jBDuHtGJ7q5J96fhFPDHXc9A7wNXtB4vnLwt8qVoGpWixuIKukP2phXUaagtZQIQbiEe5FAJp5R/RKsQKIDuDbK+aTEeqoHru8WslbRyLze+8Ai56P0aDDMwPlXJ2fvG0FeQmDnaofU9BDGpa5OGrvP598X5+IIaPkNaPjwEidVsVoLTAc6DC7uE7AjVpXD6PP+Wqiqo+2W0e/gyk49FHa4eQOWrEFa5TjKTyB4Wzko/uTSPpqrIG8HCHX9NUwjJwk2d9t99khEK7FEyk= X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Aug 2017 17:30:15.3348 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR07MB2120 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2973 Lines: 57 On Wed, Aug 02, 2017 at 05:39:01PM +0100, Catalin Marinas wrote: > Hi Yury, > > On Mon, Jul 31, 2017 at 05:48:25PM +0300, Yury Norov wrote: > > In patch 06beb72fbe23e ("arm64: introduce mm context flag to keep 32 bit task > > information") you introduce the field flags but use it only for a single flag - > > TIF_32BIT. It looks hacky to me for three reasons: > > - The flag is introduced for the case where it's impossible to get the thread > > info structure for the thread associated with mm. So thread_info flags (TIF) > > may also be unavailable at place. This is not the case for the only existing > > user of if - uprobes, but in general this approach requires to include thread > > headers in mm code, which may become unwanted dependency. > > - New flag, if it uses TIF bits, for consistency should for example set/clear > > TIF_32BIT_AARCH64 for ILP32 tasks. And to be completely consistent, with > > current approach we'd mirror thread_info flags to mm_context flags. And keep > > it syncronized. > > - If we start using TIF flags here, we cannot easily add new mm_context > > specific bits because they may mess with TIF ones. > > > > I think that this is not what was intended when you added new field in > > mm_context_t. > > TIF_32BIT was handy at the time but it indeed denotes AArch32 user > task. For ILP32 we wouldn't need to set this bit since the instruction > set is A64 and uprobe should support it (though not sure anyone tried). > I noticed in your patch introducing binfmt_ilp32.c that SET_PERSONALITY > actually sets this flag in the mm context. Depending on what will be decided here, I'll change ilp32 patch accordingly. > As with the TIF bits, the PERSONALITY macros become more complicated > with more bits to set/clear. Since we don't have any plans for other mm > context flags (independent of TIF), should we simply rename it to > thread_flags and just copy the thread_info flags: > > current->mm->context.thread_flags = current_thread_info()->flags; This will also work. But it may raise questions to one who reads the code. - if mm_context needs the threads flags, why you copy it? Why not to move flags to the mm_context_t? It is always available for thread_info users. - for multithreaded applications there might be different set of bits in the flags field in different theads. So what exactly will be in context.thread_flags is a matter of case, and you'd explain somehow which bits are reliable, and which are not. - It doesn't sound convincing to me that there are no other candidates for mm_context.flags bits. 6 month ago we didn't need the flags at all. ARM64 is under intensive development, and it's highly probable that candidates may appear one day. I don't like to add new types as well, but at the case I think, this is the most straightforward and simple way to introduce new set of bits for new bitfield. And also less questionable in maintenance perspective. Yury