From: Wu Zhangjin <wuzhangjin@gmail.com>
To: Ralf Baechle <ralf@linux-mips.org>
Cc: Arnaud Patard <apatard@mandriva.com>,
zhangfx@lemote.com, yanh@lemote.com, huhb@lemote.com,
Nicholas Mc Guire <hofrat@hofr.at>,
linux-mips@linux-mips.org
Subject: Re: [PATCH -queue v1 4/7] [loongson] lemote-2f: add pci support
Date: Sat, 07 Nov 2009 18:55:51 +0800 [thread overview]
Message-ID: <1257591351.2251.12.camel@falcon.domain.org> (raw)
In-Reply-To: <84e7310659ae445b3b3dc68aadc8f27648c709f6.1257510612.git.wuzhangjin@gmail.com>
On Fri, 2009-11-06 at 21:11 +0800, Wu Zhangjin wrote:
> From: Wu Zhangjin <wuzhangjin@gmail.com>
>
> Most of the pci support between fuloong2e and lemote loongson2f family
> machines are the same, except the cs5536 support.
>
> This patch renames ops-fuloong2e.c to ops-loongson2.c and then append
> the cs5536 support to share most of the source code among loongson
> machines.
[...]
> +
> +
> +static int loongson_pcibios_config_access(unsigned char access_type,
> + struct pci_bus *bus,
> + unsigned int devfn, int where,
> + u32 *data)
> +{
> + u32 busnum = bus->number;
> + u32 addr, type;
> + u32 dummy;
> + void *addrp;
> + int device = PCI_SLOT(devfn);
> + int function = PCI_FUNC(devfn);
> + int reg = where & ~3;
> +
> + if (busnum == 0) {
> + /* board-specific part,currently,only fuloong2f,yeeloong2f
> + * use CS5536, fuloong2e use via686b, gdium has no
> + * south bridge
> + */
> +#ifdef CONFIG_CS5536
> + /* cs5536_pci_conf_read4/write4() will call _rdmsr/_wrmsr() to
> + * access the regsters PCI_MSR_ADDR, PCI_MSR_DATA_LO,
> + * PCI_MSR_DATA_HI, which is bigger than 0xf0, so, it will not
> + * go this branch, but the others. so, no calling dead loop
> + * here.
> + */
> + if ((PCI_IDSEL_CS5536 == device) && (reg < PCI_MSR_CTRL)) {
0xf0 is exactly PCI_MSR_CTRL, will replace it by PCI_MSR_CTRL later.
Regards,
Wu Zhangjin
next prev parent reply other threads:[~2009-11-07 10:56 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-06 13:11 [PATCH -queue v1 0/7] support for lemote loongson2f machines Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 1/7] [loongson] lemote-2f: add lemote loongson2f family machines support Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 2/7] [loongson] lemote-2f: rtc: enable legacy RTC driver Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 3/7] [loongson] lemote-2f: add basic cs5536 vsm support Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 4/7] [loongson] lemote-2f: add pci support Wu Zhangjin
2009-11-07 10:55 ` Wu Zhangjin [this message]
2009-11-06 13:11 ` [PATCH -queue v1 5/7] [loongson] lemote-2f: add irq support Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 6/7] [loongson] lemote-2f: add reset and shutdown support Wu Zhangjin
2009-11-07 10:43 ` Wu Zhangjin
2009-11-06 13:11 ` [PATCH -queue v1 7/7] [loongson] lemote-2f: add defconfig file Wu Zhangjin
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=1257591351.2251.12.camel@falcon.domain.org \
--to=wuzhangjin@gmail.com \
--cc=apatard@mandriva.com \
--cc=hofrat@hofr.at \
--cc=huhb@lemote.com \
--cc=linux-mips@linux-mips.org \
--cc=ralf@linux-mips.org \
--cc=yanh@lemote.com \
--cc=zhangfx@lemote.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).