All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ksenija Stanojević" <ksenija.stanojevic@gmail.com>
To: Stefan Wahren <stefan.wahren@i2se.com>
Cc: Lee Jones <lee.jones@linaro.org>,
	linux-input@vger.kernel.org,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Jonathan Cameron <jic23@kernel.org>,
	Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Harald Geyer <harald@ccbib.org>,
	Fabio Estevam <fabio.estevam@freescale.com>,
	linux-iio@vger.kernel.org, Marek Vasut <marex@denx.de>
Subject: Re: [PATCH v13 3/5] input: touchscreen: mxs-lradc: Add support for touchscreen
Date: Wed, 1 Mar 2017 15:42:42 +0100	[thread overview]
Message-ID: <CAL7P5jKqY_4CAzvw2BiCbAPW7QEs6XNY7Qaec8GMp7Nxzp_71Q@mail.gmail.com> (raw)
In-Reply-To: <1332233362.76422.1485734109212@email.1und1.de>

[-- Attachment #1: Type: text/plain, Size: 1938 bytes --]

Hi,

On Mon, Jan 30, 2017 at 12:55 AM, Stefan Wahren <stefan.wahren@i2se.com>
wrote:
> Hi Ksenija,
>
>> Ksenija Stanojevic <ksenija.stanojevic@gmail.com> hat am 29. Januar 2017
um 19:04 geschrieben:
>>
>>
>> Add 4-wire/5-wire touchscreen controller.
>
> i compiled all 3 driver as a module and kept the devicetree for the
Olinuxino iMX233 [1] as it is (no touchscreen). After booting all 3 driver
are loaded:
> where
> Module                  Size  Used by
> mxs_lradc_adc          11000  0
> industrialio_triggered_buffer     2628  1 mxs_lradc_adc
> kfifo_buf               3337  1 industrialio_triggered_buffer
> mxs_lradc_ts            4192  0
> mxs_lradc               4402  0
> mfd_core                4612  1 mxs_lradc
>
> But the touchscreen driver threw this error:
>
> [  427.230000] mxs-lradc-ts: probe of mxs-lradc-ts failed with error -22

I think it should be like that. In earlier versions module wouldn't load if
there was no touchscreen device (it was done in the mfd part). But Lee
suggested that it there is no device it should fail in the touchscreen
driver.

> I didn't expect this behavior. I expect that the touchscreen driver
notice that there isn't a touchscreen property and abort probing silently.
Also i didn't expected that the driver is still loaded in case of a probe
error.

Well module can be loaded if probe fails see __driver_attach [1] . But in
order that driver won't load in case of probe error I think init function
should be changed somehow, unregistered driver in case of error but I'm not
sure how...

> Btw shouldn't be the mxs_lradc_adc "Used by" mxs_lradc?
>
> Because "modprobe -r mxs_lradc" doesn't unload mxs_lradc_adc.

both adc and touchscreen driver can't load if mfd part is not loaded but in
order to be listed in Used by column and unload if mfd part is unloaded I
think that they need to use symbols from the mfd part.

[1] http://lxr.free-electrons.com/source/drivers/base/dd.c#L731

[-- Attachment #2: Type: text/html, Size: 2464 bytes --]

  reply	other threads:[~2017-03-01 14:42 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-29 18:04 [PATCH v13 0/5] mxs-lradc: Split driver into MFD Ksenija Stanojevic
2017-01-29 18:04 ` Ksenija Stanojevic
2017-01-29 18:04 ` [PATCH v13 1/5] mfd: mxs-lradc: Add support for mxs-lradc MFD Ksenija Stanojevic
2017-01-29 23:15   ` Stefan Wahren
2017-01-29 18:04 ` [PATCH v13 2/5] iio: adc: mxs-lradc: Add support for adc driver Ksenija Stanojevic
2017-01-29 23:35   ` Stefan Wahren
2017-01-29 23:35     ` Stefan Wahren
2017-01-29 18:04 ` [PATCH v13 3/5] input: touchscreen: mxs-lradc: Add support for touchscreen Ksenija Stanojevic
2017-01-29 23:55   ` Stefan Wahren
2017-01-29 23:55     ` Stefan Wahren
2017-03-01 14:42     ` Ksenija Stanojević [this message]
2017-01-29 18:04 ` [PATCH v13 4/5] iio: adc: mxs-lradc: Remove driver Ksenija Stanojevic
2017-01-29 18:04   ` Ksenija Stanojevic
2017-01-29 18:04 ` [PATCH v13 5/5] mfd: Move binding document Ksenija Stanojevic

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=CAL7P5jKqY_4CAzvw2BiCbAPW7QEs6XNY7Qaec8GMp7Nxzp_71Q@mail.gmail.com \
    --to=ksenija.stanojevic@gmail.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=fabio.estevam@freescale.com \
    --cc=harald@ccbib.org \
    --cc=jic23@kernel.org \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=lee.jones@linaro.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marex@denx.de \
    --cc=pmeerw@pmeerw.net \
    --cc=stefan.wahren@i2se.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.