Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3125859pxb; Mon, 9 Nov 2020 03:21:50 -0800 (PST) X-Google-Smtp-Source: ABdhPJygJrG9vkbsdORWm1aWxcqCZ2L6IWpVEN/RFFSKx0pPWP2RLFGsdeLylSioUoCuwVR2DaGf X-Received: by 2002:a50:e181:: with SMTP id k1mr9997080edl.284.1604920910439; Mon, 09 Nov 2020 03:21:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604920910; cv=none; d=google.com; s=arc-20160816; b=gR6AD9FOE6SdbPS9MSoQ7N8d5dPM5QcBD8fCbemqUIRb/nSO5Ae7F5p0dwWVscz1MS feexBW91ab3G5vS0XDye4x8ur+TofKfiO1ebayB1C7erRvaOGbuUla47cgpU351c70pP zaREjB8P0UFZX8uLji5WxIw2C2dymVGJR0oFP5TxnfmF92ap4iqcZQnn0bC3+r9mVsGR 2HHCznmyPIrhAhmRD2rGpGwWCEYBa22VAq6cfJ0g8TJGvA53ARGCs0qQ4Pc5sM3NpMl3 e/k7+3/piOAAPU85U37Z1DiS1cShJb0OiDVW5ONq4+/EvwwzwLYg3Dr97f/2DWVx1A5C LpvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :to:subject:dkim-signature; bh=er2eQUAEHWpBLaEOsg7fH11+Tbr2OS39gTFwUEQ7HGc=; b=y/LMk4+2rX0JPqxq5lgDdvDjd4VknNFWUdwX0/zQAzmY9zRsVdjzZRBHMvcemTTMU1 T+KWD0a2PyU8LszyNWOOBq9s5Y0Z/aOEJ6Hkn/75dxm0KcnqpvAtTS0rC/X/FC/vWXV+ E2mqfSAtQLfZkHcZHqod/wPwvGg5bL2gzsgcjEAHCOXRvAQHELANnu1UmzYMKn06Us5Z R8T8DGDtddRhgoc9UTRQRmX2v5zCKyP4TPqe/SzW9RnznemWVPYBNqyyYSQ+u+9YXUuv AUXO6A5O8loQtbgeU3yWPh66j2T7ZYVftiFTNP+HiHF4bwFPU/KnzUx82LQ08dDtPfAy o5dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@monstr-eu.20150623.gappssmtp.com header.s=20150623 header.b=nkp3ey59; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r8si7061139edm.62.2020.11.09.03.21.26; Mon, 09 Nov 2020 03:21:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@monstr-eu.20150623.gappssmtp.com header.s=20150623 header.b=nkp3ey59; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729316AbgKILUD (ORCPT + 99 others); Mon, 9 Nov 2020 06:20:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33528 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726410AbgKILUD (ORCPT ); Mon, 9 Nov 2020 06:20:03 -0500 Received: from mail-ej1-x644.google.com (mail-ej1-x644.google.com [IPv6:2a00:1450:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 353DCC0613CF for ; Mon, 9 Nov 2020 03:20:01 -0800 (PST) Received: by mail-ej1-x644.google.com with SMTP id f23so5043847ejk.2 for ; Mon, 09 Nov 2020 03:20:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monstr-eu.20150623.gappssmtp.com; s=20150623; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language:content-transfer-encoding; bh=er2eQUAEHWpBLaEOsg7fH11+Tbr2OS39gTFwUEQ7HGc=; b=nkp3ey59D2+7XZdZIj/P0OhqvoTL/FYjhcGmq6xxj0jUAB1AK4nEOkhQlgU9k51HYt OaD6GXUDSVjWzbKKnsuz1ueFlFfAh1YBeKKG5iMw2qRi5rDD1nB5wRiQm3FMmTwpIDgb ze9K3El9Ac/dTvB3oBM9lY8Kw0DpWkQIA5NyG1SrjbZqdSKrqu4tCY/AexwyUUz3oLm4 EBB59NAQzB5OhL5iY+ajJ+rgNe4IP7jvDSWV73eYm2qrF+KNpO/lihwejPS0W0Km8NVZ BOKZ9yzXLDqAgEEb9zE9/MMeItOUWMwgCzHS2Z3oX0IIqktlv/gKTM1TWjRchh4jj/mw Mwig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=er2eQUAEHWpBLaEOsg7fH11+Tbr2OS39gTFwUEQ7HGc=; b=p+41GeQVWE/ZA0LHeLWlVLwpAU8Yy5TmUHXgfenMVYZPyIfDScW6mF91xRod5kUDiq 3xTSfwxvqZo7Um9aSRxlx+OqpjGhD30wz+BOJArQ1JnR9gn9Nl8MGNPoQoPLtTp2fdGg YTyedYfH1T2V2I5zwLv+/vgLwJqcudvRQusQoep2qFPf1jbMNrinCOHXoqMbjvIwP51B PDNZHN08GqhyEMnMOa1o5j7kNWR4bOx+EaTyuvvHbciidXrAD5C9+i71hRc74vg7Fkki 4ksruJXm7kUtw13UJjiMOAMeAK1UkBqTDa2xhlZ4ET4aSEicUQ7t5tSCueqh28X9/WLY 5FmQ== X-Gm-Message-State: AOAM530+8FMjiILh36n8Dk2rXIqJ00Djq0un69lqf79xbxSEmpAG0vHu 0etR2DEosSA7v4MbbN5sxd2swVOtS/Ea+B1g X-Received: by 2002:a17:906:ca93:: with SMTP id js19mr15297687ejb.537.1604920799747; Mon, 09 Nov 2020 03:19:59 -0800 (PST) Received: from [192.168.0.105] (nat-35.starnet.cz. [178.255.168.35]) by smtp.gmail.com with ESMTPSA id b1sm8472430ejg.60.2020.11.09.03.19.59 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 09 Nov 2020 03:19:59 -0800 (PST) Subject: Re: [PATCH] microblaze: add support for TIF_NOTIFY_SIGNAL To: Jens Axboe , "linux-kernel@vger.kernel.org" References: From: Michal Simek Message-ID: <894b3a46-4baa-f186-f6a1-4f818a5284e4@monstr.eu> Date: Mon, 9 Nov 2020 12:19:58 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 29. 10. 20 17:16, Jens Axboe wrote: > Wire up TIF_NOTIFY_SIGNAL handling for microblaze. > > Cc: Michal Simek > Signed-off-by: Jens Axboe > --- > > 5.11 has support queued up for TIF_NOTIFY_SIGNAL, see this posting > for details: > > https://lore.kernel.org/io-uring/20201026203230.386348-1-axboe@kernel.dk/ > > As part of that work, I'm adding TIF_NOTIFY_SIGNAL support to all archs, > as that will enable a set of cleanups once all of them support it. I'm > happy carrying this patch if need be, or it can be funelled through the > arch tree. Let me know. > > arch/microblaze/include/asm/thread_info.h | 2 ++ > arch/microblaze/kernel/signal.c | 3 ++- > 2 files changed, 4 insertions(+), 1 deletion(-) > > diff --git a/arch/microblaze/include/asm/thread_info.h b/arch/microblaze/include/asm/thread_info.h > index ad8e8fcb90d3..44f5ca331862 100644 > --- a/arch/microblaze/include/asm/thread_info.h > +++ b/arch/microblaze/include/asm/thread_info.h > @@ -107,6 +107,7 @@ static inline struct thread_info *current_thread_info(void) > #define TIF_NEED_RESCHED 3 /* rescheduling necessary */ > /* restore singlestep on return to user mode */ > #define TIF_SINGLESTEP 4 > +#define TIF_NOTIFY_SIGNAL 5 /* signal notifications exist */ > #define TIF_MEMDIE 6 /* is terminating due to OOM killer */ > #define TIF_SYSCALL_AUDIT 9 /* syscall auditing active */ > #define TIF_SECCOMP 10 /* secure computing */ > @@ -119,6 +120,7 @@ static inline struct thread_info *current_thread_info(void) > #define _TIF_SIGPENDING (1 << TIF_SIGPENDING) > #define _TIF_NEED_RESCHED (1 << TIF_NEED_RESCHED) > #define _TIF_SINGLESTEP (1 << TIF_SINGLESTEP) > +#define _TIF_NOTIFY_SIGNAL (1 << TIF_NOTIFY_SIGNAL) > #define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG) > #define _TIF_SYSCALL_AUDIT (1 << TIF_SYSCALL_AUDIT) > #define _TIF_SECCOMP (1 << TIF_SECCOMP) > diff --git a/arch/microblaze/kernel/signal.c b/arch/microblaze/kernel/signal.c > index f11a0ccccabc..5a8d173d7b75 100644 > --- a/arch/microblaze/kernel/signal.c > +++ b/arch/microblaze/kernel/signal.c > @@ -313,7 +313,8 @@ static void do_signal(struct pt_regs *regs, int in_syscall) > > asmlinkage void do_notify_resume(struct pt_regs *regs, int in_syscall) > { > - if (test_thread_flag(TIF_SIGPENDING)) > + if (test_thread_flag(TIF_SIGPENDING) || > + test_thread_flag(TIF_NOTIFY_SIGNAL)) > do_signal(regs, in_syscall); > > if (test_thread_flag(TIF_NOTIFY_RESUME)) > Applied for 5.11. Thanks, Michal -- Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91 w: www.monstr.eu p: +42-0-721842854 Maintainer of Linux kernel - Xilinx Microblaze Maintainer of Linux kernel - Xilinx Zynq ARM and ZynqMP ARM64 SoCs U-Boot custodian - Xilinx Microblaze/Zynq/ZynqMP/Versal SoCs