Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp77717rdg; Wed, 11 Oct 2023 22:05:49 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHRKy37MlhK+CSzlcYnpYJF+Nbn1N9fvdAgDncCr8NPcGjHcwBWqC3NG37N35KKlHnYJMw4 X-Received: by 2002:a17:902:e5cf:b0:1c6:349e:fa43 with SMTP id u15-20020a170902e5cf00b001c6349efa43mr24854223plf.67.1697087149162; Wed, 11 Oct 2023 22:05:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697087149; cv=none; d=google.com; s=arc-20160816; b=lMAfPHFK4XCz3OuyXhbGYk4jKrV4ur0MrPk7PiffktMPsNrA2Dno4ZcHLfmzAqo/7L w1WBhTF9u1GTozrhSsdPUvwGdiBXV8vfjoH+0cmnhJotaAIqL3/AMxTiT+9hSX8F/MDx hXnIANpdKUm6HSr/hmfuccP3n+5kko8MlW8E5zp5JCMqbDHocbV+3JucOTLF9Lq/Mxdn WdGacYnsrQduNjSbSN2q3JtgpMrw1V2I8rYl6C+joICNWIteavf2ujZ2kbQEtkXoO72B xk8bgBv8E+lX/pi4CunpzcIhrIkDPM2n+IwuMU1HIDtkP6bGIJfPeDJkhFyEwpVFHeoj JCSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=NBeCR5AU4qMW0pdc2dtiIOP2iVmTNuu0I0vdsrZzLgc=; fh=SSrIty8EiRFi/DZsy5nydz9NyRWvGtFUnvIqpC6PPL4=; b=eXG04ISSFppVtCEfG6hfBQXXKeEsuQblwHON/FUQrx0/K4B3JgZapLGpHU/hUmsJRK HDfmMhn90aiy6uoj4lklxDrqfqyGCd8W30unBLve1KkAi7He9ZyQlD3HC+JCU8SczJTa zL+LFd2M010Z6NUwcCJnKEexxsEll6CXOo3pg3D1tCUfQBSDvLGtgrIpvc1g3LBWrs/o N54cGZoura5D2fbWBjWGF2kbPKnzIDzyuKNLmvH+ran2b5CA1z8GL6n8++dBnm8iN8jF O+w5Qvgv/451JjY8mAxdnFmjbM0477atxanrciZ25npbzyP3DT13d30EK9Q8c2OR4owy IH4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="h/GgI+Pd"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id u14-20020a170902e5ce00b001b222cd9826si1447836plf.349.2023.10.11.22.05.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Oct 2023 22:05:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="h/GgI+Pd"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id A66D080A64C6; Wed, 11 Oct 2023 22:05:46 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376998AbjJLFFf (ORCPT + 99 others); Thu, 12 Oct 2023 01:05:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235228AbjJLFFd (ORCPT ); Thu, 12 Oct 2023 01:05:33 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ADB6890; Wed, 11 Oct 2023 22:05:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1697087132; x=1728623132; h=date:from:to:cc:subject:message-id:references: mime-version:content-transfer-encoding:in-reply-to; bh=qAqfjH4EeTiWuaON92xe5Ip4YWDBD4AvbFVckiNoGcs=; b=h/GgI+PdFp/Y/bnhHOuHXxjEk0/nGWMGwZCDNji5f5wZ7trSrsLzGGXk gCU+p96bvuKOGuQN0GBZK+PqJDxaWuRZmNRwbsSBWZXOKLKHfDExWUxE7 ThOPuDJF/mwOKaElcxwugs/D+n0HkczgzdGOke4tSbQ3zKGJ89Oe+HBjm DZcr0D4Ex1pVda+H15R4as7oe+a9/4x+E7pm75tmIMoc7d74DZ6Ik/Yfh VWdzMhklCXCA8SQvE+Vku6e8MO1y8w0rHwOu/+QjLmNgPHNQIGL6h5FcS LazqihB8E92Zr3eRh3wSeRKxX86yo5un0eOO+oHSB0ax8i5Jztp3AL3rb Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10860"; a="382073058" X-IronPort-AV: E=Sophos;i="6.03,217,1694761200"; d="scan'208";a="382073058" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Oct 2023 22:05:32 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10860"; a="870418848" X-IronPort-AV: E=Sophos;i="6.03,217,1694761200"; d="scan'208";a="870418848" Received: from yilunxu-optiplex-7050.sh.intel.com (HELO localhost) ([10.239.159.165]) by fmsmga002.fm.intel.com with ESMTP; 11 Oct 2023 22:05:30 -0700 Date: Thu, 12 Oct 2023 13:04:34 +0800 From: Xu Yilun To: Rob Herring Cc: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] fpga: altera-ps-spi: Use spi_get_device_match_data() Message-ID: References: <20231006224624.444857-1-robh@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 11 Oct 2023 22:05:46 -0700 (PDT) On Mon, Oct 09, 2023 at 07:48:07AM -0500, Rob Herring wrote: > On Sat, Oct 7, 2023 at 2:56 AM Xu Yilun wrote: > > > > On Sat, Oct 07, 2023 at 03:43:41PM +0800, Xu Yilun wrote: > > > On Fri, Oct 06, 2023 at 05:46:24PM -0500, Rob Herring wrote: > > > > Use preferred spi_get_device_match_data() instead of of_match_device() and > > > > spi_get_device_id() to get the driver match data. With this, adjust the > > > > includes to explicitly include the correct headers. > > > > > > > > Signed-off-by: Rob Herring > > > > > > Acked-by: Xu Yilun > > > > > > Applied. > > > > > > > > > > > static const struct spi_device_id altera_ps_spi_ids[] = { > > > > - { "cyclone-ps-spi", CYCLONE5 }, > > > > - { "fpga-passive-serial", CYCLONE5 }, > > > > - { "fpga-arria10-passive-serial", ARRIA10 }, > > > > + { "cyclone-ps-spi", (uintptr_t)&c5_data }, > > > > + { "fpga-passive-serial", (uintptr_t)&c5_data }, > > > > + { "fpga-arria10-passive-serial", (uintptr_t)&a10_data }, > > > > Sorry, one more. Should cast to kernel_ulong_t? > > Either will work. uintptr_t is somewhat new in the kernel and > preferred now I think. LGTM, Applied. > > Rob