Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp4389156rwd; Tue, 23 May 2023 07:09:24 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7H2AsqZUJ3M+7hl1kuYP0smp6Sc3YTXb9avdvclIsWW/xevCFx5HVG+qthMFCONRIgyEIP X-Received: by 2002:a17:902:c20c:b0:1a8:626:6d9d with SMTP id 12-20020a170902c20c00b001a806266d9dmr14178088pll.62.1684850964546; Tue, 23 May 2023 07:09:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684850964; cv=none; d=google.com; s=arc-20160816; b=oBUi8vVFH/Q02zXuJ1zJU3m0RZuB7yjJJDwyhph1k+EImn4YD65o2Uw3jpyYSSoZhz dIbSNaXysTzfFOiYqYm6MhsF7EL2t6oV+LSSfcAhDbZnjAphScK213offjpJeorEgovt mqU2oLiZpFznXcmbZIdmuIiJrU/Ab9vHCdRPuzsn8NCIDvI/WUjFClwR745D4v7JZqBQ sPjwzOuTZWAMOpQov5aGjJbzwO9a80NSMBelo+14YTeU+y17LlF+iMyYr/4emYABYULZ Yp1e2FowQklyJqXZhIO1zSqiqVBD/n535NiNtNRncJ3v1TiMVcuEQMpCrg86MIsTG2cU Xj+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=b/3885L94lN4KFkmIG4KL0Z1VLtyVywWWWjhcZ8AdCI=; b=U9vprZ1pIDH97fv03zsvm5cvMMf0oZK4qN5ym5NpUoP6MPmkyiaDX0ESY+OgUhHFD7 nVGwKl67iFOfFGmCK84Kt/yNo6Y+8p03aBadklv3FCTmYHJ1jPzuv8OGcjwxXqrcSxNs vwASsmMDZYhcqYy/FyliCynIFaEoyV16ybnKlOycMnBzly87kw3nBqE4zNbPOEZ1DijU /26gCmHhnSakIRnoMHadVeyouz6O5iRi1RLVbrVUZzTMhhmvhza/SCqQO1SIX88ctNc4 eWiGbUPcvslGTZjIlGFlUSNI1btLumWiHtAtVB2a7s/EL/UDphznUM41F5oJyEywCBr0 QouQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=qhdr9VIe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q7-20020a170902a3c700b001ae533bccc7si2119083plb.322.2023.05.23.07.09.11; Tue, 23 May 2023 07:09:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=qhdr9VIe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237127AbjEWOHY (ORCPT + 99 others); Tue, 23 May 2023 10:07:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46918 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237129AbjEWOHM (ORCPT ); Tue, 23 May 2023 10:07:12 -0400 Received: from mail-lf1-f52.google.com (mail-lf1-f52.google.com [209.85.167.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AF4C018D for ; Tue, 23 May 2023 07:06:51 -0700 (PDT) Received: by mail-lf1-f52.google.com with SMTP id 2adb3069b0e04-4f380cd1019so8398205e87.1 for ; Tue, 23 May 2023 07:06:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1684850750; x=1687442750; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=b/3885L94lN4KFkmIG4KL0Z1VLtyVywWWWjhcZ8AdCI=; b=qhdr9VIeHm3TCAUgvcaHfodtBDTuWxK2iXj6V/SQ66zUErdAk9+DCvdLTF4aCd1ETu C+ZAXFKiOs20Y/LEEtHSq1dPudVvh6HRokN0i21bR1zIMcVKbUmCrYz24kNjxTLPVXAa cFSvLYM8x6ZBwAnEtC4zHJP9yI7e0Y76rr1w29rfD59OhfMtbLcaAZOSrbcUgEQ+zCmx caIJ/LOff8nHxBYzP4GFpPBpy1b42pU47PMbeKWiMmKuOjXR5pkLmpUVwA4W9JWmR+b4 CDnpYKOJa/b0/Br6Vk3EN6ig9EeMV6vmOvhLsCfhbrFKneL3zoOIRn+iLLV6tfwCA1tP yGJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684850750; x=1687442750; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=b/3885L94lN4KFkmIG4KL0Z1VLtyVywWWWjhcZ8AdCI=; b=lkDZhpQCYcHjhMVA7ddeZybJcHCQNQMt+y0vsU1LkcVwst+19CSF7yHRj2wsK2jPVr sb4hGVlcf3LsXcUXxxLXUqumUeNwAMjL4yHtLLLHwBiKe1JDpqghgMqUk8PAuYDI3+RT Zp1cmPNkBhC5O3LlzWBPlnoqb+VJQAUUvUPJ1AtLt1NYXfaiN2X8Syq1WBF5tqGleFV/ C4Eeq21GKTDw3ofYQyGpTYcHFt1vOhg6Hghmkhk34q0whqAB8KeE6+pGYgQd2+63egmw ILq3k+2T8orS/e31pbdwmBTow6LcKK1w9epoxF6eA8ILkZDSPCJGAr3Y5YNOZ3G4OZ1V w6SA== X-Gm-Message-State: AC+VfDwEp7DcGrbvmzNbDtdiStEEqzABsBj/u3NoPGhIlPvFQBMLTPpN gz0OhBP52iQtG9ickWTOTcT5kA== X-Received: by 2002:ac2:52aa:0:b0:4ef:d6e2:6530 with SMTP id r10-20020ac252aa000000b004efd6e26530mr4123672lfm.37.1684850750175; Tue, 23 May 2023 07:05:50 -0700 (PDT) Received: from [127.0.1.1] ([85.235.12.238]) by smtp.gmail.com with ESMTPSA id h28-20020ac2597c000000b004e9bf853c27sm1346562lfp.70.2023.05.23.07.05.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 May 2023 07:05:49 -0700 (PDT) From: Linus Walleij Date: Tue, 23 May 2023 16:05:29 +0200 Subject: [PATCH v3 05/12] cifs: Pass a pointer to virt_to_page() MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230503-virt-to-pfn-v6-4-rc1-v3-5-a16c19c03583@linaro.org> References: <20230503-virt-to-pfn-v6-4-rc1-v3-0-a16c19c03583@linaro.org> In-Reply-To: <20230503-virt-to-pfn-v6-4-rc1-v3-0-a16c19c03583@linaro.org> To: Andrew Morton , Geert Uytterhoeven , Vineet Gupta , Catalin Marinas , Will Deacon , Arnd Bergmann , Russell King , Greg Ungerer Cc: linux-mm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-snps-arc@lists.infradead.org, linux-fsdevel@vger.kernel.org, linux-cifs@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arch@vger.kernel.org, Linus Walleij , Tom Talpey X-Mailer: b4 0.12.1 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Like the other calls in this function virt_to_page() expects a pointer, not an integer. However since many architectures implement virt_to_pfn() as a macro, this function becomes polymorphic and accepts both a (unsigned long) and a (void *). Fix this up with an explicit cast. Acked-by: Tom Talpey Signed-off-by: Linus Walleij --- fs/cifs/smbdirect.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/cifs/smbdirect.c b/fs/cifs/smbdirect.c index 0362ebd4fa0f..964f07375a8d 100644 --- a/fs/cifs/smbdirect.c +++ b/fs/cifs/smbdirect.c @@ -2500,7 +2500,7 @@ static ssize_t smb_extract_kvec_to_rdma(struct iov_iter *iter, if (is_vmalloc_or_module_addr((void *)kaddr)) page = vmalloc_to_page((void *)kaddr); else - page = virt_to_page(kaddr); + page = virt_to_page((void *)kaddr); if (!smb_set_sge(rdma, page, off, seg)) return -EIO; -- 2.34.1