From: Andrew Morton <akpm@linux-foundation.org>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: jeff@garzik.org, linux-ide@vger.kernel.org
Subject: Re: [PATCH] pata_hpt37x: Fix outstanding bug reports on the HPT374 and 37x cable detect
Date: Mon, 5 Nov 2007 18:42:45 -0800 [thread overview]
Message-ID: <20071105184245.e45bc3b9.akpm@linux-foundation.org> (raw)
In-Reply-To: <20071105225338.20ef476f@the-village.bc.nu>
On Mon, 5 Nov 2007 22:53:38 +0000 Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
> +static u32 hpt374_read_freq(struct pci_dev *pdev)
> +{
> + u32 freq;
> + unsigned long io_base = pci_resource_start(pdev, 4);
> + if (PCI_FUNC(pdev->devfn) & 1) {
> + struct pci_dev *pdev_0 = pci_get_slot(pdev->bus, pdev->devfn - 1);
> + /* Someone hot plugged the controller on us ? */
> + if (pdev_0 == NULL)
> + return 0;
> + io_base = pci_resource_start(pdev_0, 4);
> + freq = inl(io_base + 0x90);
> + pci_dev_put(pdev_0);
> + }
> + else
> + freq = inl(io_base + 0x90);
> + return freq;
> +}
hm, pci_resource_start() returns a resource_size_t and I guess this (and a
heck of a lot of other) code is bust on (whatever machine we added that for).
next prev parent reply other threads:[~2007-11-06 2:43 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-05 22:53 [PATCH] pata_hpt37x: Fix outstanding bug reports on the HPT374 and 37x cable detect Alan Cox
2007-11-06 2:42 ` Andrew Morton [this message]
2007-11-06 10:40 ` Alan Cox
2007-11-06 14:45 ` Sergei Shtylyov
2007-11-06 14:59 ` Alan Cox
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=20071105184245.e45bc3b9.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=jeff@garzik.org \
--cc=linux-ide@vger.kernel.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.