Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp718549imm; Fri, 1 Jun 2018 08:23:10 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLKwXOKzfOaH/OLWGPXiYtuUbLlbR3E1QeOM1w4zDalHI2UkpPbpIAKuVbZqwTOKCmhlW3q X-Received: by 2002:a17:902:8a:: with SMTP id a10-v6mr11450469pla.89.1527866590430; Fri, 01 Jun 2018 08:23:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527866590; cv=none; d=google.com; s=arc-20160816; b=z0OVmQzX8XYZFVAz/fTbzdqjAoGmokwqx6/SWcmQBXW/zsk1C370fSW1xlRZtXqTkB bkSTEA0lxX/jI/o13J+5fEJOlOSs0wjELIYpiltHDpfR8hG+dePM8FbW5D9CWrWv7t03 lwA19LhXFeKt4MpupJtPpzKwjYAhZbQ3VLiAG+b8Dx73sav58V6hOnrJGMRLZlZzkxX4 yIMWIpLWjEahq2iG2s4VaSdYNe7J/2787ulKnIg5UsInXjrHbIo4DUo8eM0fOCqWmqtz TNinOdJu74cLdf+Yej90WnOj0XG8tpS3p2580hPQAeoFgHbQwQYNy0uS/MWFvUuEia5l C0/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=qjaKeqGZTNtyKDB29BC3b3duYKuphy5mWD5cteCyIjs=; b=jAvaXneDBfQcISqMUlo8O4yGXbUGxJLyKUsj3//YqHyAeupACErgA5mENIsTQpE/vT Q8Kt+nASmnDy2dZHzIUugk9HqseSGdylWaMnFeEaGH/4am3C1//ydSvOvXSpRfdJQtKt p3n6IRWy/r+3jGk4yclM+0LlFFWMq/cDzl7bnM2/fbWMamdfqzQhFZKukrG9g4CqStMA 6st7/BidOh3/V06Vi1S+c6OtSzeKtxEoeZL3P1pwhcprQllnK9WmfsDFZbMvcoNymxH3 2GRG29U5Qd4nZy7DtmCCjoUqDAC4Jw9HEnzxkgWJ+HCoq4/tMTDFP8X/f0aoRerbhiA3 /XqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=o+V/qAqQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n12-v6si14203267plp.123.2018.06.01.08.22.56; Fri, 01 Jun 2018 08:23:10 -0700 (PDT) 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=@gmail.com header.s=20161025 header.b=o+V/qAqQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752970AbeFAPVf (ORCPT + 99 others); Fri, 1 Jun 2018 11:21:35 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:52176 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752067AbeFAPVa (ORCPT ); Fri, 1 Jun 2018 11:21:30 -0400 Received: by mail-wm0-f68.google.com with SMTP id r15-v6so3738264wmc.1 for ; Fri, 01 Jun 2018 08:21:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=qjaKeqGZTNtyKDB29BC3b3duYKuphy5mWD5cteCyIjs=; b=o+V/qAqQly9WPpOR/gD+pHeQvCio6i6VUOV1O9dIXFuxdMOg0CzMDQl8T3BaKvTJ93 5AOvznOn0YdoV2WUUkY/XuxgvIaxQIN548EEGlzW8rz5cc81ayzZsDHfZriihvEn/TBd zN85mlXlBkWDGyczfyEtOMuOGLWul3LoVD8TsJr9AqLPueFNUGcwuBmkEbEItqUiGdxl 0li629WAkXMlIEFPrzzteXBoMnF/AFVS0TRaTGHnFXEn/r6yTDrozz0RoRC7xMZRf85n dY9ZBAeyylJyF0hm8CElGXJa1Xd/0v9oHU1LX9Ie3couxiKbok9GE+mQKGtCWDrEIXj4 LgOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=qjaKeqGZTNtyKDB29BC3b3duYKuphy5mWD5cteCyIjs=; b=rxn6Jbmt8e+d8vIObs/tFxITDwNz5c0YGWOXSpUafnWf1AhvEFIFFjIol0OBy4zjQ9 9cYwRxJxHeu+WaDXaLzs9yx2I3rn4Wk9oOYkdnZ2vV+nFPBJQ7mxPBJIyaHBbRsQAFcq qpkCCb6KK+SwG623agnNpoTPzX+1uzV4AV4m6SLrqHsT+hXSyu7cv2RUxg2jHnQzUBRO Q3i/sY9TWIOZ/mzrFX0feKtEBV6IkdpoefjGPLPuioXDfgR5k2wfqeLsDQJGbQOgTpUP 3gWDAeF92NChwrZf9FfSNTGstglobMzlyuBTqsD9MxT3S0AAgXophizkPMw9R7QeGUdN jK4Q== X-Gm-Message-State: ALKqPwf5PO3hgKL+cNUmQM70BVBNkSOKmVorSOLpEUjA6UsbIdMZQCAs rnTXKlBdlCjBLE8MtYgu1Xg= X-Received: by 2002:a50:b1cb:: with SMTP id n11-v6mr13140902edd.197.1527866489487; Fri, 01 Jun 2018 08:21:29 -0700 (PDT) Received: from localhost.localdomain ([2a02:a03f:4023:8a00:1051:9318:8490:3b94]) by smtp.gmail.com with ESMTPSA id j16-v6sm516409edp.22.2018.06.01.08.21.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 01 Jun 2018 08:21:28 -0700 (PDT) From: Luc Van Oostenryck To: Palmer Dabbelt Cc: Albert Ou , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, Luc Van Oostenryck Subject: [PATCH 1/3] riscv: use NULL instead of a plain 0 Date: Fri, 1 Jun 2018 17:21:21 +0200 Message-Id: <20180601152123.47256-2-luc.vanoostenryck@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180601152123.47256-1-luc.vanoostenryck@gmail.com> References: <20180601152123.47256-1-luc.vanoostenryck@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org sbi_remote_sfence_vma() & sbi_remote_fence_i() takes a pointer as first argument but some macros call them with a plain 0 which, while legal C, is frowned upon in the kernel. Change this by replacing the 0 by NULL. Signed-off-by: Luc Van Oostenryck --- arch/riscv/include/asm/cacheflush.h | 2 +- arch/riscv/include/asm/tlbflush.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/riscv/include/asm/cacheflush.h b/arch/riscv/include/asm/cacheflush.h index efd89a88d..8f1307441 100644 --- a/arch/riscv/include/asm/cacheflush.h +++ b/arch/riscv/include/asm/cacheflush.h @@ -47,7 +47,7 @@ static inline void flush_dcache_page(struct page *page) #else /* CONFIG_SMP */ -#define flush_icache_all() sbi_remote_fence_i(0) +#define flush_icache_all() sbi_remote_fence_i(NULL) void flush_icache_mm(struct mm_struct *mm, bool local); #endif /* CONFIG_SMP */ diff --git a/arch/riscv/include/asm/tlbflush.h b/arch/riscv/include/asm/tlbflush.h index 7b209aec3..85c2d8bae 100644 --- a/arch/riscv/include/asm/tlbflush.h +++ b/arch/riscv/include/asm/tlbflush.h @@ -49,7 +49,7 @@ static inline void flush_tlb_range(struct vm_area_struct *vma, #include -#define flush_tlb_all() sbi_remote_sfence_vma(0, 0, -1) +#define flush_tlb_all() sbi_remote_sfence_vma(NULL, 0, -1) #define flush_tlb_page(vma, addr) flush_tlb_range(vma, addr, 0) #define flush_tlb_range(vma, start, end) \ sbi_remote_sfence_vma(mm_cpumask((vma)->vm_mm)->bits, \ -- 2.17.1