All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Langsdorf <mlangsdo-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Brijesh Singh <brijesh.singh-5C7GfCeVMHo@public.gmane.org>,
	Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	mark.rutland-5wv7dgnIgG8@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	pawel.moll-5wv7dgnIgG8@public.gmane.org,
	ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org,
	linux-ide-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org,
	tj-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org
Subject: Re: [PATCH] ata: add AMD Seattle platform driver
Date: Mon, 11 Jan 2016 09:33:21 -0600	[thread overview]
Message-ID: <5693CB41.70408@redhat.com> (raw)
In-Reply-To: <5690367E.8060609-5C7GfCeVMHo@public.gmane.org>

On 01/08/2016 04:21 PM, Brijesh Singh wrote:
> Hi,

>> We generally don't refer to register locations with properties other than
>> 'reg', so that approach would be worse. What I'd suggest you do is to
>> have the sgpio registers in a separate device node, and use the LED
>> binding to access it, see
>>
>> Documentation/devicetree/bindings/leds/common.txt
>>
>> It seems that none of the drivers/ata/ drivers use the leds interface
>> today, but that can be added to libata-*.c whenever the appropriate
>> properties are there.
>>
>
> libata-*.c implements the "Enclosure management" style led messages but also has hooks
> to register a custom led control callback. Since Seattle platform does not support
> the "Enclosure management" registers hence ata_port_info we are setting a ATA_FLAG_EM | ATA_FLAG_SW_ACIVITY
> to indicate that we can still handle the led messages by our registered callback. I see
> that sata_highbank driver is doing something similar.

The sata_highbank driver is doing it wrong and shouldn't have been
accepted in its current condition. Enclosure management really should
be a separate device. Please don't use it as an example.

--Mark Langsdorf

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

WARNING: multiple messages have this Message-ID (diff)
From: mlangsdo@redhat.com (Mark Langsdorf)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ata: add AMD Seattle platform driver
Date: Mon, 11 Jan 2016 09:33:21 -0600	[thread overview]
Message-ID: <5693CB41.70408@redhat.com> (raw)
In-Reply-To: <5690367E.8060609@amd.com>

On 01/08/2016 04:21 PM, Brijesh Singh wrote:
> Hi,

>> We generally don't refer to register locations with properties other than
>> 'reg', so that approach would be worse. What I'd suggest you do is to
>> have the sgpio registers in a separate device node, and use the LED
>> binding to access it, see
>>
>> Documentation/devicetree/bindings/leds/common.txt
>>
>> It seems that none of the drivers/ata/ drivers use the leds interface
>> today, but that can be added to libata-*.c whenever the appropriate
>> properties are there.
>>
>
> libata-*.c implements the "Enclosure management" style led messages but also has hooks
> to register a custom led control callback. Since Seattle platform does not support
> the "Enclosure management" registers hence ata_port_info we are setting a ATA_FLAG_EM | ATA_FLAG_SW_ACIVITY
> to indicate that we can still handle the led messages by our registered callback. I see
> that sata_highbank driver is doing something similar.

The sata_highbank driver is doing it wrong and shouldn't have been
accepted in its current condition. Enclosure management really should
be a separate device. Please don't use it as an example.

--Mark Langsdorf

WARNING: multiple messages have this Message-ID (diff)
From: Mark Langsdorf <mlangsdo@redhat.com>
To: Brijesh Singh <brijesh.singh@amd.com>, Arnd Bergmann <arnd@arndb.de>
Cc: linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, mark.rutland@arm.com,
	devicetree@vger.kernel.org, pawel.moll@arm.com,
	ijc+devicetree@hellion.org.uk, linux-ide@vger.kernel.org,
	robh+dt@kernel.org, galak@codeaurora.org, tj@kernel.org
Subject: Re: [PATCH] ata: add AMD Seattle platform driver
Date: Mon, 11 Jan 2016 09:33:21 -0600	[thread overview]
Message-ID: <5693CB41.70408@redhat.com> (raw)
In-Reply-To: <5690367E.8060609@amd.com>

On 01/08/2016 04:21 PM, Brijesh Singh wrote:
> Hi,

>> We generally don't refer to register locations with properties other than
>> 'reg', so that approach would be worse. What I'd suggest you do is to
>> have the sgpio registers in a separate device node, and use the LED
>> binding to access it, see
>>
>> Documentation/devicetree/bindings/leds/common.txt
>>
>> It seems that none of the drivers/ata/ drivers use the leds interface
>> today, but that can be added to libata-*.c whenever the appropriate
>> properties are there.
>>
>
> libata-*.c implements the "Enclosure management" style led messages but also has hooks
> to register a custom led control callback. Since Seattle platform does not support
> the "Enclosure management" registers hence ata_port_info we are setting a ATA_FLAG_EM | ATA_FLAG_SW_ACIVITY
> to indicate that we can still handle the led messages by our registered callback. I see
> that sata_highbank driver is doing something similar.

The sata_highbank driver is doing it wrong and shouldn't have been
accepted in its current condition. Enclosure management really should
be a separate device. Please don't use it as an example.

--Mark Langsdorf

  parent reply	other threads:[~2016-01-11 15:33 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-07 20:53 [PATCH] ata: add AMD Seattle platform driver Brijesh Singh
2016-01-07 20:53 ` Brijesh Singh
2016-01-07 20:53 ` Brijesh Singh
2016-01-07 21:25 ` Arnd Bergmann
2016-01-07 21:25   ` Arnd Bergmann
2016-01-07 22:24   ` Brijesh Singh
2016-01-07 22:24     ` Brijesh Singh
2016-01-07 22:24     ` Brijesh Singh
2016-01-07 23:42     ` Arnd Bergmann
2016-01-07 23:42       ` Arnd Bergmann
2016-01-08  1:46       ` Brijesh Singh
2016-01-08  1:46         ` Brijesh Singh
2016-01-08  1:46         ` Brijesh Singh
2016-01-08  8:46         ` Arnd Bergmann
2016-01-08  8:46           ` Arnd Bergmann
2016-01-08 22:21           ` Brijesh Singh
2016-01-08 22:21             ` Brijesh Singh
2016-01-08 22:21             ` Brijesh Singh
2016-01-08 22:47             ` Arnd Bergmann
2016-01-08 22:47               ` Arnd Bergmann
2016-01-11 18:56               ` Brijesh Singh
2016-01-11 18:56                 ` Brijesh Singh
2016-01-11 18:56                 ` Brijesh Singh
     [not found]                 ` <5693FAC2.4070003-5C7GfCeVMHo@public.gmane.org>
2016-01-12 14:24                   ` Arnd Bergmann
2016-01-12 14:24                     ` Arnd Bergmann
2016-01-12 14:24                     ` Arnd Bergmann
2016-01-13 16:55                     ` Brijesh Singh
2016-01-13 16:55                       ` Brijesh Singh
2016-01-13 16:55                       ` Brijesh Singh
2016-01-13 20:39                       ` Arnd Bergmann
2016-01-13 20:39                         ` Arnd Bergmann
     [not found]             ` <5690367E.8060609-5C7GfCeVMHo@public.gmane.org>
2016-01-11 15:33               ` Mark Langsdorf [this message]
2016-01-11 15:33                 ` Mark Langsdorf
2016-01-11 15:33                 ` Mark Langsdorf
2016-01-11 16:55                 ` Brijesh Singh
2016-01-11 16:55                   ` Brijesh Singh
2016-01-11 16:55                   ` Brijesh Singh
2016-01-07 22:56   ` Rob Herring
2016-01-07 22:56     ` Rob Herring
2016-01-08 19:59 ` Joe Perches
2016-01-08 19:59   ` Joe Perches
2016-01-11 10:23 ` Hans de Goede
2016-01-11 10:23   ` Hans de Goede

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=5693CB41.70408@redhat.com \
    --to=mlangsdo-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=brijesh.singh-5C7GfCeVMHo@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
    --cc=ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-ide-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=pawel.moll-5wv7dgnIgG8@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=tj-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    /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.