Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1666762pxb; Wed, 9 Feb 2022 01:39:26 -0800 (PST) X-Google-Smtp-Source: ABdhPJwXW8mUIVqQyjVn8Yzd2V5ik4sl819Hmn5vaIbSUI6YSu4ENBGdZt4M5PXT+R4FZTELqFz+ X-Received: by 2002:a17:90a:7108:: with SMTP id h8mr2431933pjk.240.1644399565904; Wed, 09 Feb 2022 01:39:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644399565; cv=none; d=google.com; s=arc-20160816; b=gz7oS+0viSGkkp2Gg6DO54W8iFN1n4PPst8t0ef1YbjRLmd46BmW9Mk+PC24BN1+ky g7ixkUJK6Q7R9IftNNQUfKHZ6TzDnOLqBf5ZV1TzZkfrED6X6eI/Ee/4Ft90uRpikOQp tCz8b/99SiFDV/PAH+NHzv1y4uEWRTxyIMdpd8pmq4tQMO8ztKadkAkfhNC7XBuT6RU8 ZYiQgT4OoYB9IiWnAmzrjZ5WhMlSMcVPvHgWhQ00c84oYnn+mzcxb11VymKBTCQqMyu9 OCoc7o7hd+ojUuuti7zjCokGX5c3m7m2LAYh2tInt1b8IkEj21mrhWWHA6N2Vri/piLN n0zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=yr1DP4d1HD2ycEU97bhXbMtopP3Oy+ED1MZNuHmeMYw=; b=Pfj0w4S/Sd9rKrx1DUdo4Tohpwf1sopgA9wLVj3/YVOMcMHIUts17Y9e7VjUkPi4fE 72qVsdtZbGL+ygeQWN8PyozL3fINU96OCmd6ju+xke2z7pu3U7twfzJXPjb/wVYaP/Vl uvANih7JFG9+aIQpQXrg7oxiy8reaAWjDy6R+KJMqr+WEtBOqSXBOvcXjAnuQZpCajL9 8+XSjG9N4uJzhNXezcGTzVLbBeYKpJJ/fLBVWhFqzIly9h1lUAlE8VIgy+ytba2V3hIp /Lhybs6GUTIOGzv1y/MmQFxd+JEZE/GlY2ESjA7+Z9GGsMBVxoXnJ0Z6aAspSWOXFBA8 L6XQ== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id y3si14969334pgp.711.2022.02.09.01.39.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Feb 2022 01:39:25 -0800 (PST) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 746FBC1DF8C2; Wed, 9 Feb 2022 01:03:37 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244544AbiBGWa6 (ORCPT + 99 others); Mon, 7 Feb 2022 17:30:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52104 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235284AbiBGWa5 (ORCPT ); Mon, 7 Feb 2022 17:30:57 -0500 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0F453C0612A4 for ; Mon, 7 Feb 2022 14:30:57 -0800 (PST) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id AED8521102; Mon, 7 Feb 2022 22:30:55 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 27E6E13C72; Mon, 7 Feb 2022 22:30:53 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id NJGDNp2dAWK3CgAAMHmgww (envelope-from ); Mon, 07 Feb 2022 22:30:53 +0000 Date: Mon, 7 Feb 2022 14:23:48 -0800 From: Davidlohr Bueso To: kernel test robot Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org, Song Liu Subject: [PATCH] md/raid5: silence sparse warnings wrt struct raid5_percpu Message-ID: <20220207222348.wbokxgsdvmxhbidd@offworld> References: <202202072158.7y7wxNRC-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <202202072158.7y7wxNRC-lkp@intel.com> User-Agent: NeoMutt/20211029 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Move out the nested declaration of the percpu bits of struct r5conf and silence sparse complaining about address spaces: drivers/md/raid5.c:7070:9: sparse: sparse: cast removes address space '__percpu' of expression drivers/md/raid5.c:7070:9: warning: incorrect type in argument 1 (different address spaces) drivers/md/raid5.c:7070:9: expected struct lockdep_map *lock drivers/md/raid5.c:7070:9: got struct lockdep_map [noderef] __percpu * drivers/md/raid5.c:7070:9: warning: incorrect type in argument 1 (different address spaces) drivers/md/raid5.c:7070:9: expected struct local_lock_t [usertype] *l drivers/md/raid5.c:7070:9: got struct local_lock_t [noderef] __percpu * Reported-by: kernel test robot Signed-off-by: Davidlohr Bueso --- drivers/md/raid5.h | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/drivers/md/raid5.h b/drivers/md/raid5.h index 9e8486a9e445..125b925e2b0c 100644 --- a/drivers/md/raid5.h +++ b/drivers/md/raid5.h @@ -560,6 +560,17 @@ struct r5pending_data { struct bio_list bios; }; +/* per cpu variables */ +struct raid5_percpu { + struct page *spare_page; /* Used when checking P/Q in raid6 */ + void *scribble; /* space for constructing buffer + * lists and performing address + * conversions + */ + int scribble_obj_size; + local_lock_t lock; +}; + struct r5conf { struct hlist_head *stripe_hashtbl; /* only protect corresponding hash list and inactive_list */ @@ -634,16 +645,7 @@ struct r5conf { * Cleared when a sync completes. */ int recovery_disabled; - /* per cpu variables */ - struct raid5_percpu { - struct page *spare_page; /* Used when checking P/Q in raid6 */ - void *scribble; /* space for constructing buffer - * lists and performing address - * conversions - */ - int scribble_obj_size; - local_lock_t lock; - } __percpu *percpu; + struct raid5_percpu __percpu *percpu; int scribble_disks; int scribble_sectors; struct hlist_node node; -- 2.35.1