public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Moritz Fischer <moritz.fischer@ettus.com>
To: iztok.jeras@redpitaya.com
Cc: p.zabel@pengutronix.de, linux-kernel@vger.kernel.org
Subject: Re: Reset implementation for Zynq
Date: Fri, 21 Oct 2016 10:04:38 -0700	[thread overview]
Message-ID: <20161021170438.GA4307@live.com> (raw)
In-Reply-To: <20161021030847.6b4c15d01df5508dab02973c2a5944d9.645b3cfd21.mailapi@email21.godaddy.com>

Iztok,

On Fri, Oct 21, 2016 at 03:08:47AM -0700, iztok.jeras@redpitaya.com wrote:
> Hi Moritz,
>  
> I was looking at your reset implementation for Zynq:
> https://github.com/Xilinx/linux-xlnx/blob/629041605b93343ad2e8971ceaac3edcef0b043b/drivers/reset/reset-zynq.c
> I went through related mailing list posts (including earlier versions of the patch) so I kind of understand what to change in the device tree.

Please look at the upstream kernel sources and use the mailing list
(lkml) if you want to report bugs. Xilinx' vendor tree might or might
not be up to date.

> I would like to use this driver to reset the Zynq I2C controller, since we have trouble with it getting into a lock up state.
> I plan to use function device_reset_optional() from:
> https://github.com/Xilinx/linux-xlnx/blob/629041605b93343ad2e8971ceaac3edcef0b043b/include/linux/reset.h
>  
> But this function is calling the reset function pointer from the reset_control_ops structure.
> For the zynq driver this function pointer is not defined, only assert, deassert and status are.
>  
> Is this a missing implementation, or is there a default implementation (I did not find one) which which performs an assert+deassert,
> or is there another set of reset APIs I should use inside the kernel.

You could just call reset_control_assert() and reset_control_deassert().
You're right there is currently no implementation for the 'reset' function for
zynq (and most of the other SoCs). I'll need to see if it makes sense at
all.

Please note that you'd probably have to modify the i2c driver to
integrate reset functionality cleanly.

Thanks,

Moritz

       reply	other threads:[~2016-10-21 17:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20161021030847.6b4c15d01df5508dab02973c2a5944d9.645b3cfd21.mailapi@email21.godaddy.com>
2016-10-21 17:04 ` Moritz Fischer [this message]
2016-10-24  9:00   ` Reset implementation for Zynq Philipp Zabel
2016-10-24 17:03     ` Moritz Fischer
2016-11-08  6:34   ` Shubhrajyoti Datta
     [not found]     ` <20161108024052.6b4c15d01df5508dab02973c2a5944d9.803a60fc5b.mailapi@email21.godaddy.com>
2016-11-08 11:56       ` Shubhrajyoti Datta

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=20161021170438.GA4307@live.com \
    --to=moritz.fischer@ettus.com \
    --cc=iztok.jeras@redpitaya.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=p.zabel@pengutronix.de \
    /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