From patchwork Thu Feb 22 19:09:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yosry Ahmed X-Patchwork-Id: 13567983 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5EEC6C5478C for ; Thu, 22 Feb 2024 19:09:17 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C720F6B007E; Thu, 22 Feb 2024 14:09:16 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id C20D26B0080; Thu, 22 Feb 2024 14:09:16 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id AE8AE6B0081; Thu, 22 Feb 2024 14:09:16 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 9B6E46B007E for ; Thu, 22 Feb 2024 14:09:16 -0500 (EST) Received: from smtpin07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id 60317140F3A for ; Thu, 22 Feb 2024 19:09:16 +0000 (UTC) X-FDA: 81820377912.07.C4BBC60 Received: from mail-yw1-f201.google.com (mail-yw1-f201.google.com [209.85.128.201]) by imf27.hostedemail.com (Postfix) with ESMTP id 9C1C640020 for ; Thu, 22 Feb 2024 19:09:14 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=SbYAy58K; spf=pass (imf27.hostedemail.com: domain of 32ZvXZQoKCKQcSWVcELQIHKSSKPI.GSQPMRYb-QQOZEGO.SVK@flex--yosryahmed.bounces.google.com designates 209.85.128.201 as permitted sender) smtp.mailfrom=32ZvXZQoKCKQcSWVcELQIHKSSKPI.GSQPMRYb-QQOZEGO.SVK@flex--yosryahmed.bounces.google.com; dmarc=pass (policy=reject) header.from=google.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1708628954; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:dkim-signature; bh=nIzMjlB25RgjrxXtl1pB1geOeDMH3Njm73h3nfH079U=; b=bMWgYYs06g76uN8aflvzQPiDpdLs5mE3H1iaigC81iM9Nxurg0cH9xrzfA8J0trIkBsHSw O7KBFIHE9dajPdJWRNSIpslZ/sp4s/75thkhcFPaN8ryEb+cZCBhdsCRQe+DufC9Sjp7NU 7fBN+Z1MyZVkMljWV+cyC7Cs2C1qGYU= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1708628954; a=rsa-sha256; cv=none; b=jvbI1QWAxGzO7yEE5BCMuEK9xLKK1JxVgIeD7QXQaqIlwoEBrgBbLwZeam7eC2YPMvx7TF rBtA32cJ86aBrw+lGDF1TTBRW12Ql+djr/kTaou1fYJFpIPfyNmlwYH2V/9XUJQ0ItOhYn 9XTqCL+22utdFU2/rE2BE5Dg6KhN0No= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=SbYAy58K; spf=pass (imf27.hostedemail.com: domain of 32ZvXZQoKCKQcSWVcELQIHKSSKPI.GSQPMRYb-QQOZEGO.SVK@flex--yosryahmed.bounces.google.com designates 209.85.128.201 as permitted sender) smtp.mailfrom=32ZvXZQoKCKQcSWVcELQIHKSSKPI.GSQPMRYb-QQOZEGO.SVK@flex--yosryahmed.bounces.google.com; dmarc=pass (policy=reject) header.from=google.com Received: by mail-yw1-f201.google.com with SMTP id 00721157ae682-607838c0800so13110337b3.1 for ; Thu, 22 Feb 2024 11:09:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1708628953; x=1709233753; darn=kvack.org; h=cc:to:from:subject:message-id:mime-version:date:from:to:cc:subject :date:message-id:reply-to; bh=nIzMjlB25RgjrxXtl1pB1geOeDMH3Njm73h3nfH079U=; b=SbYAy58KQF2JBQDQMvzZDArh7sQqu00vFBs/U0Aci12PGVe7bmDJqz11WPcfSmKLrE /BlZY0DEtG8Df5xlqSVvYSzTe3yd5qgigIlKdoJjLJIhLLSOXC8RvVc48ZAP+4ayNaau 84LF+GJiqgcpYwlu9FWd17EcAB8tsOFHv/afrAj9qjTUlVZpJaAKk1LanrKou+QCjzWy wyEtq63kH8NFYAg14jllkxcW1OfBnVQCEjP31JhQsr8Xt7jR3ZdKRhh8OdWyF4Fwg4PX uTtdbXYGnEQksOvmBnho2CQ1p1Brm0LPUnI9cOms3hsrkTYEcLyeFCET7eZ87LaIJWcC LmTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708628953; x=1709233753; h=cc:to:from:subject:message-id:mime-version:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=nIzMjlB25RgjrxXtl1pB1geOeDMH3Njm73h3nfH079U=; b=izfJe84uN8r6AOfG8QbKhognXjmo16XiKrt1l3LL/ctBNrSEco08PHCggfplntGCkd 99LjlovkQ6CtcGEzbpK5QI4S44P3fgVsWmcIFINJPp5aUBLwfKyPl+ZT9ILYYstnFQVM jYU74gP6rWpUdwiZytnaQfe8WiZk2xuUGtDrb0Y8PsZRtgpq+2SmEpPKn3XL8THJ3s/I gookRJTzHgu3pUInIU2QrkIqeM3ScajlcBiC8IQyaVSRqL7souhMbyQu7gXnhoqxo82j sXBQ59UOzbtbxqadNhQMxoI32+C6k5XJjt2h2itCTwUzlcfl9m3C+8SqOrHca1yS4pSP 82vA== X-Forwarded-Encrypted: i=1; AJvYcCWjGJlLThZgO1BVjNJMApjAHeyF2jOfvvNwkrGZ8oKDdcMl6pn6c1jgvNz1P1sgB4ypWkdpnhCK4jFjr2bzdjmSwPw= X-Gm-Message-State: AOJu0Yz6zeTXOK4FPAqas9JNx7AYQdFEMug4UHWogOUQl/a8JCC82Q7O BGUFXuMk6QzK9rlVF0j+Gm055Li+jP4QICIBp9vHpGDj3euSb0mPLyb6csjAJiaRFDZamK2X93G CeRdYn6yrBBObF6gGsQ== X-Google-Smtp-Source: AGHT+IFhLOIIoOxOJTeZtK8v5l/nxmb62wdg4S32WZNNAZyEiVU1cXXF13e3K+xCwfoSZI1v2GPL5kT56V9ooklX X-Received: from yosry.c.googlers.com ([fda3:e722:ac3:cc00:20:ed76:c0a8:29b4]) (user=yosryahmed job=sendgmr) by 2002:a25:7496:0:b0:dcc:5463:49a8 with SMTP id p144-20020a257496000000b00dcc546349a8mr657549ybc.6.1708628953740; Thu, 22 Feb 2024 11:09:13 -0800 (PST) Date: Thu, 22 Feb 2024 19:09:10 +0000 Mime-Version: 1.0 X-Mailer: git-send-email 2.44.0.rc1.240.g4c46232300-goog Message-ID: <20240222190911.1903054-1-yosryahmed@google.com> Subject: [PATCH mm-stable 1/2] x86/mm: further clarify switch_mm_irqs_off() documentation From: Yosry Ahmed To: Andrew Morton Cc: Dave Hansen , Ingo Molnar , Thomas Gleixner , Borislav Petkov , Dave Hansen , Andy Lutomirski , Peter Zijlstra , x86@kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Yosry Ahmed X-Stat-Signature: sdj44yxkimcxbfqikkan3fo5wt9nfd6p X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 9C1C640020 X-Rspam-User: X-HE-Tag: 1708628954-237478 X-HE-Meta: U2FsdGVkX1+MDJaDhZEq1VFUk8ZgXT+F4Zg/9NRfYz8m5gO+C1Ah30qno+IfSUWTp4KMrNuMN1GZ0ntL7XQ2BCGn/z5lblbSSsqTKM2uyF/AjuBUALFBErxDB8eMkQuC9i5xEzRI55N02x0M/MmJC6bc/b8iZxdyIhlZah52lsDmzESs4mD+5xKB5SFhjh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rYhDEjLYljhDkrYMYpucetCpe53J95G0jyjQYLDg07m8n6Ibrd5dL7HjMMLvFWHjG277CSwgW+1cunqsUuMU31bcN+NahQKqE9SXCQ8yd8RJRG1KNKQYLhXw1onVBX40QPVRGg9RcKIQ5nM/4eZMF9c+NElVrwOJGVHSJ/HIrZO1vV6na7giJYVLXcexuWayQZqnl8BjOXXQLerOa9EwEU9CxTUhlKxZztBXc7DkZylFDo28lzA7c09i/itmJKD2TkOTOhMklY5a+hrHzcGswpRYiCL6PPBvuis/UiXfltHNeV80zJHo4AT7LWlHWiNWZgt9PwtYphzMmhZqIRlPiI8ORwip4kqElyxpIoGzLfALOotvzZPPCoE05Y61+1o09gtT1UcXNzeATAaR0EV3OzI7ube4yPCRXFQulhZkRBiRd+i/Otpu1oOa73aARkg== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Commit accf6b23d1e5a ("x86/mm: clarify "prev" usage in switch_mm_irqs_off()") attempted to clarify x86's usage of the arguments passed by generic code, specifically the "prev" argument the is unused by x86. However, it could have done a better job with the comment above switch_mm_irqs_off(). Rewrite this comment according to Dave Hansen's suggestion. Fixes: accf6b23d1e5 ("x86/mm: clarify "prev" usage in switch_mm_irqs_off()") Suggested-by: Dave Hansen Signed-off-by: Yosry Ahmed Acked-by: Dave Hansen --- arch/x86/mm/tlb.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/x86/mm/tlb.c b/arch/x86/mm/tlb.c index bf9605caf24f7..b67545baf6973 100644 --- a/arch/x86/mm/tlb.c +++ b/arch/x86/mm/tlb.c @@ -493,10 +493,10 @@ static inline void cr4_update_pce_mm(struct mm_struct *mm) { } #endif /* - * The "prev" argument passed by the caller does not always match CR3. For - * example, the scheduler passes in active_mm when switching from lazy TLB mode - * to normal mode, but switch_mm_irqs_off() can be called from x86 code without - * updating active_mm. Use cpu_tlbstate.loaded_mm instead. + * This optimizes when not actually switching mm's. Some architectures use the + * 'unused' argument for this optimization, but x86 must use + * 'cpu_tlbstate.loaded_mm' instead because it does not always keep + * 'current->active_mm' up to date. */ void switch_mm_irqs_off(struct mm_struct *unused, struct mm_struct *next, struct task_struct *tsk) From patchwork Thu Feb 22 19:09:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yosry Ahmed X-Patchwork-Id: 13567984 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id D9227C54791 for ; Thu, 22 Feb 2024 19:09:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 6A5786B0080; Thu, 22 Feb 2024 14:09:18 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 655436B0081; Thu, 22 Feb 2024 14:09:18 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4CF856B0082; Thu, 22 Feb 2024 14:09:18 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 3E9D16B0080 for ; Thu, 22 Feb 2024 14:09:18 -0500 (EST) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 130FA40E0C for ; Thu, 22 Feb 2024 19:09:18 +0000 (UTC) X-FDA: 81820377996.20.87DDC18 Received: from mail-yw1-f202.google.com (mail-yw1-f202.google.com [209.85.128.202]) by imf24.hostedemail.com (Postfix) with ESMTP id 4E55F18002C for ; Thu, 22 Feb 2024 19:09:16 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=ruy7gc0n; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf24.hostedemail.com: domain of 325vXZQoKCKYeUYXeGNSKJMUUMRK.IUSROTad-SSQbGIQ.UXM@flex--yosryahmed.bounces.google.com designates 209.85.128.202 as permitted sender) smtp.mailfrom=325vXZQoKCKYeUYXeGNSKJMUUMRK.IUSROTad-SSQbGIQ.UXM@flex--yosryahmed.bounces.google.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1708628956; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=KUYsRE8+tSPKyWViBth/a0r1Ckkz1G0ugYjkWT2KW0I=; b=gfPmwGlUw8jnWtU68V11Q3l5MLEM8EqIYnCcMZd07FMWu9vROhU1GYC7QUUTBBJ0x1YGTF HcpnkPvzZpUGFBY0XUcMZ+1lSkW6hqUK25IJ1ksmN6QxeQa1z0r+cKpp29CcEVtuKoJHwm FW4lW5Jj+t9nJ/fWR/+GYd4+cCu6SP4= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=ruy7gc0n; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf24.hostedemail.com: domain of 325vXZQoKCKYeUYXeGNSKJMUUMRK.IUSROTad-SSQbGIQ.UXM@flex--yosryahmed.bounces.google.com designates 209.85.128.202 as permitted sender) smtp.mailfrom=325vXZQoKCKYeUYXeGNSKJMUUMRK.IUSROTad-SSQbGIQ.UXM@flex--yosryahmed.bounces.google.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1708628956; a=rsa-sha256; cv=none; b=67Dmlq3LuNPQOdTeyObr9eRyxVMcrzaG/r5LunrAPREdiSJ8NnDRsDsj5ZWPLQIGIY7YSR HW7nj1O5QlqoWv8EUiOYAiYxzIKZ8Lg/H0w/a3UHYUxrz0EmBxJ5dg84Gfb4612BrvYUhp /NzEIGHCMSi3mfjUZruMk3dv01PJPGo= Received: by mail-yw1-f202.google.com with SMTP id 00721157ae682-608ac8c5781so1197467b3.3 for ; Thu, 22 Feb 2024 11:09:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1708628955; x=1709233755; darn=kvack.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=KUYsRE8+tSPKyWViBth/a0r1Ckkz1G0ugYjkWT2KW0I=; b=ruy7gc0nkUCMdwu8BNI+OQdciotoimnYkzOx1cmyCt1HtSLeQSjxSIsLbkKpyxeQPz R9+bR7slQqMry9XOa+opWi1zLoneYblyD4L1ZlGMnlenwvxGMor1v0tGJ+pKBGcZKucf S2yuJQLQsa49XT6ToF5QyjW08SJSJdF0tcah8Zf7L85U1dXITNDlyDwCz61zf5v1pkxm OkGvBt0dSa6vCD1Za6puFnVEmmJwMBwmx6R/WyVSiU/EOEvilCa2cChU3eB9vHsV8gyS bA8B7YpnS30yAFg56p0QEQ+rIfghHXoIILpt8B2SR/yFP4dIsJucCW85oXfks11cPSpT 9Abg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708628955; x=1709233755; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=KUYsRE8+tSPKyWViBth/a0r1Ckkz1G0ugYjkWT2KW0I=; b=Zz4gggtiQK9HCFceFAz4nQ17X/z0rW6dNTv5RBm44TwUp4WSJPFd/Urwt/KrdO1P4T 7SMeXM8hue0DUyioVVC1FtSZlUWr2yYKQE4g7fc5UpaCr4/ZOj8i7MCQbFCFHGBmge6I wzGJVqZ2m5UQA/DOlIDGAompml4ZzTAP1jThlYRoQHumW4mXiZAo0Ymla5EMDULzYHs6 VyhUm212dtJluZhDpgBtraz4gdcXurmgI+VgA0KwP9Vpr3H/x9VLpc21+5eS6mpTFllU WLAUbdrhi+HNehSNAQsGR1SJVKpjX00+Q6adidDZYLR86m04jxALFe2KaEihAKnDm0jx mA5w== X-Forwarded-Encrypted: i=1; AJvYcCUb4jhE9kpxa4W550wpETRFH6UpnhmEkNRninhWzBZCzYljYXw51hxjs64U2Owj9PsJhRz6KGoASkbUHtEUoeW9PcM= X-Gm-Message-State: AOJu0YzC64P8vTLOtdbX3VQjq7zCehmuzTJQ/eV5hYgHkrV6ZkiPvY+8 r/IpLZ7EGl8WgExJk51YMRxRRIJmIbbI+IH5MT9XftDr0IvBtuBbNRomylzslJlvUCpieYNpmtX ALHFRo8Yi+j6A5ChvPw== X-Google-Smtp-Source: AGHT+IGNUOZEq4h2q64sDVSpAxoKqvTsDClH9Jr8J8zrGhX1hRnuFcUuoek/5uwALBgmzAO3wKmtgeHhgPdv5I2J X-Received: from yosry.c.googlers.com ([fda3:e722:ac3:cc00:20:ed76:c0a8:29b4]) (user=yosryahmed job=sendgmr) by 2002:a25:abd0:0:b0:dc6:cafd:dce5 with SMTP id v74-20020a25abd0000000b00dc6cafddce5mr6172ybi.12.1708628955435; Thu, 22 Feb 2024 11:09:15 -0800 (PST) Date: Thu, 22 Feb 2024 19:09:11 +0000 In-Reply-To: <20240222190911.1903054-1-yosryahmed@google.com> Mime-Version: 1.0 References: <20240222190911.1903054-1-yosryahmed@google.com> X-Mailer: git-send-email 2.44.0.rc1.240.g4c46232300-goog Message-ID: <20240222190911.1903054-2-yosryahmed@google.com> Subject: [PATCH mm-stable 2/2] x86/mm: always pass NULL as the first argument of switch_mm_irqs_off() From: Yosry Ahmed To: Andrew Morton Cc: Dave Hansen , Ingo Molnar , Thomas Gleixner , Borislav Petkov , Dave Hansen , Andy Lutomirski , Peter Zijlstra , x86@kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Yosry Ahmed X-Rspam-User: X-Rspamd-Server: rspam12 X-Rsp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QOMWRuF9PdoIKk3Sh417+ORvH4JW7AtKtougpEglrZnzUpur1JU2MymbkYjlu9JONurbZVLEPVlrFUJH1bRqlb9MkawyxzsqieUjJOKiPdj67jcjNzLf0841AMG5AHrHUvb8jruQjk3ZdaHw7kYXtYXaCxUXpuNm6W2b17X5tLQ0gUVIPOzbNNTPOBVeWYE4Qqd/WEHawPFYWQRGcwQLreP5XZfAvz/ZZu98ffAOQDjpKi64smWGxLTGMI2uwlrPFDAu6Izfu3R0n7+7Hb2XCBk0D7FsuKH9Er0w+CWILkaFEY+JluvA5qFs1LznyyrXhNirrJ7SsLOrX06Mttkx/BOWs2MfrVZ4FKO6qE9Hh/GC3GNuhPAy7VMqwenJI+LEFzXtI/JWLyKGE8IYPIPy0MV24ryMcPXzZzNYtU3ArWDfdae36A0IkxuUMFH0u/QwoerXBH3z+ICAzpBHoKTBPhaSBA5sFmnZcw/uO8w02vkTLjGEhxFzOmEmfwZc/rF9115D3lx1B/y46PEw4hcbNGjlbqg3Zrx4Twf6cbsJldVZwDbugNHkAOR8/0V//I5PIpGcId43hNU3s3tCAaZGjddYCY67omsgmEimbp9fFl+QPQ+oFDolTYU3Vx1215Kb7Cphocrx570HYvzaDI4ympVyzoq32lmKM9ohcDxcI9+mG4XXx6kQxJZzHcAR4BUzj7/C9eaOVle0X3I2l1A== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: The first argument of switch_mm_irqs_off() is unused by the x86 implementation. Make sure that x86 code never passes a non-NULL value to make this clear. Update the only non violating caller, switch_mm(). Suggested-by: Dave Hansen Signed-off-by: Yosry Ahmed Acked-by: Dave Hansen --- arch/x86/mm/tlb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/mm/tlb.c b/arch/x86/mm/tlb.c index b67545baf6973..51f9f56941058 100644 --- a/arch/x86/mm/tlb.c +++ b/arch/x86/mm/tlb.c @@ -327,7 +327,7 @@ void switch_mm(struct mm_struct *prev, struct mm_struct *next, unsigned long flags; local_irq_save(flags); - switch_mm_irqs_off(prev, next, tsk); + switch_mm_irqs_off(NULL, next, tsk); local_irq_restore(flags); }