linux-fpga.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Xu Yilun <yilun.xu@linux.intel.com>
Cc: Moritz Fischer <mdf@kernel.org>, Wu Hao <hao.wu@intel.com>,
	Xu Yilun <yilun.xu@intel.com>, Tom Rix <trix@redhat.com>,
	linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fpga: altera-ps-spi: Use spi_get_device_match_data()
Date: Mon, 9 Oct 2023 07:48:07 -0500	[thread overview]
Message-ID: <CAL_JsqKB4gqT06NnWj0Qkd0TuryYA15tjMSom1f+dMJfevy2Zw@mail.gmail.com> (raw)
In-Reply-To: <ZSEO5NrJl/kxd7LG@yilunxu-OptiPlex-7050>

On Sat, Oct 7, 2023 at 2:56 AM Xu Yilun <yilun.xu@linux.intel.com> 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 <robh@kernel.org>
> >
> > Acked-by: Xu Yilun <yilun.xu@intel.com>
> >
> > 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.

Rob

  reply	other threads:[~2023-10-09 12:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-06 22:46 [PATCH] fpga: altera-ps-spi: Use spi_get_device_match_data() Rob Herring
2023-10-07  7:43 ` Xu Yilun
2023-10-07  7:55   ` Xu Yilun
2023-10-09 12:48     ` Rob Herring [this message]
2023-10-12  5:04       ` Xu Yilun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAL_JsqKB4gqT06NnWj0Qkd0TuryYA15tjMSom1f+dMJfevy2Zw@mail.gmail.com \
    --to=robh@kernel.org \
    --cc=hao.wu@intel.com \
    --cc=linux-fpga@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mdf@kernel.org \
    --cc=trix@redhat.com \
    --cc=yilun.xu@intel.com \
    --cc=yilun.xu@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).