linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mika Westerberg <mika.westerberg@linux.intel.com>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	Jonathan Cameron <jic23@kernel.org>,
	linux-iio@vger.kernel.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Sascha Weisenberger <sascha.weisenberger@siemens.com>
Subject: Re: [PATCH] iio: adc: Add support for TI ADC1x8s102
Date: Tue, 25 Apr 2017 15:30:29 +0300	[thread overview]
Message-ID: <20170425123029.GS7152@lahna.fi.intel.com> (raw)
In-Reply-To: <2a116105-0046-bcc1-b560-f6986220fb4b@siemens.com>

On Tue, Apr 25, 2017 at 02:17:23PM +0200, Jan Kiszka wrote:
> I'm not ACPI guru: How do we come from a SSDT to information that is
> carried in the DSDT so far? How can we overload wrong information in the
> built in DSDT this way? I'm all ears if we could fix our (and also the
> Galileo) quirks like that!

SSDT stands for Secondary System Description table which basically adds
stuff to DSDT (the main table). Main use for SSDTs is to add devices but
you can also amend an existing device in DSDT by adding methods and so
forth.

In case of Galileo the SPI1 host controller happens to miss _CRS method
so we can use SSDT like below to add that method there:

Scope (\_SB.PCI0.SPI1)
{
    Name (_CRS, ResourceTemplate () {
        GpioIo (Exclusive, PullUp, 0, 0, IoRestrictionOutputOnly,
                "\\_SB.PCI0.GIP0.GPO", 0) {2} // MUX6_IO
    })

    Name (_DSD, Package () {
        ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
        Package () {
            Package () {
                "cs-gpios", Package () {^SPI1, 0, 0, 0},
            },
        }
    })
}

This effectively means that once the table is parsed we find the SPI1
device with two new methods, _CRS and _DSD and the kernel is happy to
handle the rest.

Important thing here is the

	Scope (\_SB.PCI0.SPI1)

which allows us to reference an object in DSDT.

  reply	other threads:[~2017-04-25 12:32 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-24 19:28 [PATCH] iio: adc: Add support for TI ADC1x8s102 Jan Kiszka
2017-04-24 20:05 ` Andy Shevchenko
2017-04-24 20:10   ` Andy Shevchenko
2017-04-24 20:37     ` Jan Kiszka
2017-04-24 20:32   ` Jan Kiszka
2017-04-24 21:25     ` Andy Shevchenko
2017-04-25  5:44       ` Jan Kiszka
2017-04-25  9:42         ` Andy Shevchenko
2017-04-25 10:53           ` Jan Kiszka
2017-04-25 11:27             ` Andy Shevchenko
2017-04-25 11:35               ` Mika Westerberg
2017-04-25 12:17                 ` Jan Kiszka
2017-04-25 12:30                   ` Mika Westerberg [this message]
2017-04-25 13:47                     ` Jan Kiszka
2017-04-25 16:12                       ` Jan Kiszka
2017-04-26  9:01                         ` Mika Westerberg
2017-04-27  6:01                           ` Jonathan Cameron
2017-04-27  6:04                             ` Jonathan Cameron
2017-05-19 16:01                             ` Mark Brown
2017-05-20 16:26                               ` Jonathan Cameron
2017-05-22 10:06                                 ` Mark Brown
2017-04-25  6:06   ` Jan Kiszka
2017-04-25  7:31 ` Peter Meerwald-Stadler
2017-04-25  9:20   ` Andy Shevchenko
2017-04-25  9:32   ` Jan Kiszka
2017-04-25 11:23     ` Andy Shevchenko
2017-04-25 12:20       ` Mika Westerberg
2017-04-26  5:37   ` Jan Kiszka
2017-04-26 10:21     ` Andy Shevchenko
2017-04-27  6:14 ` Jonathan Cameron

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=20170425123029.GS7152@lahna.fi.intel.com \
    --to=mika.westerberg@linux.intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=jan.kiszka@siemens.com \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sascha.weisenberger@siemens.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).