mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Antony Pavlov <antonynpavlov@gmail.com>
To: barebox <barebox@lists.infradead.org>
Subject: add_usb_ehci_device() don't set resource size
Date: Wed, 24 Aug 2011 18:30:35 +0400	[thread overview]
Message-ID: <CAA4bVAEHnV+d8JMXqTKtNWKdvfmXaS=S8S=KQBPRTQhbt8EnJg@mail.gmail.com> (raw)

Hi!

add_usb_ehci_device() don't set resource size, it only set start address:

struct device_d *add_usb_ehci_device(int id, resource_size_t hccr,
                resource_size_t hcor, void *pdata)
{
        struct device_d *dev;

        dev = alloc_device("ehci", id, pdata);
        dev->resource = xzalloc(sizeof(struct resource) * 2);
        dev->num_resources = 2;
        dev->resource[0].start = hccr;
        dev->resource[0].flags = IORESOURCE_MEM;
        dev->resource[1].start = hcor;
        dev->resource[1].flags = IORESOURCE_MEM;

        register_device(dev);

        return dev;
}

So on my Tegra board I have this:

toshiba ac100> / devinfo ehci0
resources:
num   : 0
start : 0xc5000100
size  : 0x00000000
        ^^^^^^^^^^
num   : 1
start : 0xc5000140
size  : 0x00000000
        ^^^^^^^^^^
driver: ehci

-- 
Best regards,
  Antony Pavlov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

             reply	other threads:[~2011-08-24 14:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-24 14:30 Antony Pavlov [this message]
2011-08-24 16:27 ` Sascha Hauer

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='CAA4bVAEHnV+d8JMXqTKtNWKdvfmXaS=S8S=KQBPRTQhbt8EnJg@mail.gmail.com' \
    --to=antonynpavlov@gmail.com \
    --cc=barebox@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox