From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CDDB4EEC0 for ; Sun, 26 Apr 2026 16:21:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777220468; cv=none; b=MnNHMjOcx91gUh3bB8NTrRw8Zx+5M57PRJg/Ja5T+UN79QTRvMAlIv6fv2RUYpBU+XYaW86dMW5tLMln/kgHeXo3OpFyjA6EP7XA7vtk8N9xY1GHhYdokjGzbx4iDbQAkFEKaAxG59IJ66ueBGIb/wt9oUOtdfi3IJHyJgkizDY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777220468; c=relaxed/simple; bh=kfyGBbKxlHxqbh7uHBoHaiJB8t7j1QFeZX063q6kYq8=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=HwFlUADBz/q8fZT7LK/x4NK0ou43x1zxfCXWTrM+8QFXOFG7gTq5ZTQj36238TjKvheescGTxUvsY7ioS7cLf6puGobHMMMnvsc/bvjgIw8677Rt9A0CQq0iSt9PF1K0MuoyvDWi0riVaygI5/dsyi3s5iZt7eWEW/LrsEbYUWA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=gZXrxkQP; arc=none smtp.client-ip=170.10.133.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="gZXrxkQP" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1777220465; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type; bh=lgG/9hpt6SdVt7Vuwe0Oilo+O7zmyP/FYMPNF7Ijhzw=; b=gZXrxkQPxQjj/LcMvgbxKv4vhfXHWh+sd0pPVOxkpqg05wd1RHvJDYj8gFWF/+CsGVFr8L ZpsBwOe+m1E41ySWzq/dYmNOvMeSasJeTlhOWqgYuA3/WPK93GyvQPDs7pJr273LAYLfJm vNhFX881O32O8dbDcynF0qVvXOET9UM= Received: from mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-286-F_PFpdzSO3KxK8SU8uo4Pg-1; Sun, 26 Apr 2026 12:21:04 -0400 X-MC-Unique: F_PFpdzSO3KxK8SU8uo4Pg-1 X-Mimecast-MFC-AGG-ID: F_PFpdzSO3KxK8SU8uo4Pg_1777220463 Received: from mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.111]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 7E25B1800454; Sun, 26 Apr 2026 16:21:03 +0000 (UTC) Received: from fedora (unknown [10.44.48.22]) by mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with SMTP id 4D629180047F; Sun, 26 Apr 2026 16:21:01 +0000 (UTC) Received: by fedora (nbSMTP-1.00) for uid 1000 oleg@redhat.com; Sun, 26 Apr 2026 18:21:03 +0200 (CEST) Date: Sun, 26 Apr 2026 18:21:00 +0200 From: Oleg Nesterov To: Andrew Morton Cc: linux-kernel@vger.kernel.org Subject: [PATCH 1/2] dequeue_synchronous_signal: use SI_FROMKERNEL() Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.111 Cosmetic, to make the intent more clear to the reader. Signed-off-by: Oleg Nesterov --- kernel/signal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/signal.c b/kernel/signal.c index d65d0fe24bfb..9924489c43a5 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -681,8 +681,8 @@ static int dequeue_synchronous_signal(kernel_siginfo_t *info) * Return the first synchronous signal in the queue. */ list_for_each_entry(q, &pending->list, list) { - /* Synchronous signals have a positive si_code */ - if ((q->info.si_code > SI_USER) && + /* Synchronous signals are always from kernel */ + if (SI_FROMKERNEL(&q->info) && (sigmask(q->info.si_signo) & SYNCHRONOUS_MASK)) { sync = q; goto next; -- 2.52.0