linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jiaxun Yang <jiaxun.yang@flygoat.com>
To: "Tiezhu Yang" <yangtiezhu@loongson.cn>
Cc: "Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
	"Huacai Chen" <chenhc@lemote.com>,
	"Bjorn Helgaas" <bhelgaas@google.com>,
	"Jens Axboe" <axboe@kernel.dk>,
	"linux-mips" <linux-mips@vger.kernel.org>,
	"linux-pci" <linux-pci@vger.kernel.org>,
	"linux-ide" <linux-ide@vger.kernel.org>,
	"linux-kernel" <linux-kernel@vger.kernel.org>,
	"Xuefeng Li" <lixuefeng@loongson.cn>
Subject: 回复:[PATCH 3/6] MIPS: Loongson: Use firmware arguments to get board name
Date: Mon, 09 Mar 2020 16:36:41 +0800	[thread overview]
Message-ID: <170be7063d1.c7d52ae02285.4730966984142345992@flygoat.com> (raw)
In-Reply-To: <1583742206-29163-4-git-send-email-yangtiezhu@loongson.cn>



 ---- 在 星期一, 2020-03-09 16:23:23 Tiezhu Yang <yangtiezhu@loongson.cn> 撰写 ----
 > In order to distinguish various types of bridge chip such as AMD RS780E
 > or Loongson 7A1000, we can use firmware arguments to get board name.
 > 
Hi Tiezhu,

Thanks for your contribution.
Your series is sightly conflict with my "modernize" series. But that's fine,
if your code can meet mainline requirement, I'm going to adjust my works. 

See my comments bellow.

 > Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
 > ---
 >  arch/mips/include/asm/mach-loongson64/boot_param.h | 1 +
 >  arch/mips/loongson64/env.c                         | 5 +++++
 >  2 files changed, 6 insertions(+)
 > 
 > diff --git a/arch/mips/include/asm/mach-loongson64/boot_param.h b/arch/mips/include/asm/mach-loongson64/boot_param.h
 > index 8c286be..225a563 100644
 > --- a/arch/mips/include/asm/mach-loongson64/boot_param.h
 > +++ b/arch/mips/include/asm/mach-loongson64/boot_param.h
 > @@ -217,5 +217,6 @@ struct loongson_system_configuration {
 >  
 >  extern struct efi_memory_map_loongson *loongson_memmap;
 >  extern struct loongson_system_configuration loongson_sysconf;
 > +extern struct board_devices *eboard;
 >  
 >  #endif
 > diff --git a/arch/mips/loongson64/env.c b/arch/mips/loongson64/env.c
 > index 0daeb7b..a244a8c 100644
 > --- a/arch/mips/loongson64/env.c
 > +++ b/arch/mips/loongson64/env.c
 > @@ -24,6 +24,9 @@ EXPORT_SYMBOL(cpu_clock_freq);
 >  struct efi_memory_map_loongson *loongson_memmap;
 >  struct loongson_system_configuration loongson_sysconf;
 >  
 > +struct board_devices *eboard;
 > +EXPORT_SYMBOL(eboard);

Can we make it as a part of struct loongson_sysconf and export that struct?
Memory of struct eboard is not managed by kernel,  we shouldn't export such symbol.

Also I noticed that you're checking PCH type repeatly in other subsystems. Can you just
determine the PCH type here?

 > +
 >  u64 loongson_chipcfg[MAX_PACKAGES] = {0xffffffffbfc00180};
 >  u64 loongson_chiptemp[MAX_PACKAGES];
 >  u64 loongson_freqctrl[MAX_PACKAGES];
 > @@ -51,6 +54,8 @@ void __init prom_init_env(void)
 >          ((u64)loongson_p + loongson_p->system_offset);
 >      ecpu = (struct efi_cpuinfo_loongson *)
 >          ((u64)loongson_p + loongson_p->cpu_offset);
 > +    eboard = (struct board_devices *)
 > +        ((u64)loongson_p + loongson_p->boarddev_table_offset);
 >      eirq_source = (struct irq_source_routing_table *)
 >          ((u64)loongson_p + loongson_p->irq_offset);
 >      loongson_memmap = (struct efi_memory_map_loongson *)
 > -- 
 > 2.1.0
 > 
 >

  reply	other threads:[~2020-03-09  8:52 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-09  8:23 [PATCH 0/6] Add basic support for Loongson 7A1000 bridge chip Tiezhu Yang
2020-03-09  8:23 ` [PATCH 1/6] PCI: Add Loongson vendor ID and 7A1000 device IDs Tiezhu Yang
2020-03-09  8:50   ` 回复:[PATCH " Jiaxun Yang
2020-03-10  2:31     ` Tiezhu Yang
2020-03-10  2:37       ` Jiaxun Yang
2020-03-10  9:28         ` Tiezhu Yang
2020-03-09  8:23 ` [PATCH 2/6] AHCI: Add support for Loongson 7A1000 SATA controller Tiezhu Yang
2020-03-09  8:23 ` [PATCH 3/6] MIPS: Loongson: Use firmware arguments to get board name Tiezhu Yang
2020-03-09  8:36   ` Jiaxun Yang [this message]
2020-03-10  2:38     ` 回复:[PATCH " Tiezhu Yang
2020-03-09  8:23 ` [PATCH 4/6] MIPS: Loongson: Add DMA support for 7A1000 Tiezhu Yang
2020-03-09  8:44   ` 回复:[PATCH " Jiaxun Yang
2020-03-10  2:40     ` Tiezhu Yang
2020-03-13  8:24   ` [PATCH " Christoph Hellwig
2020-03-13  9:03     ` Tiezhu Yang
2020-03-09  8:23 ` [PATCH 5/6] MIPS: Loongson: Add PCI " Tiezhu Yang
2020-03-09  8:47   ` 回复:[PATCH " Jiaxun Yang
2020-03-10  3:03     ` Tiezhu Yang
2020-03-09  8:23 ` [PATCH 6/6] MIPS: Loongson: Add support for 7A1000 interrupt controller Tiezhu Yang
2020-03-09  9:07   ` 回复:[PATCH " Jiaxun Yang
2020-03-10  4:28     ` Tiezhu Yang

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=170be7063d1.c7d52ae02285.4730966984142345992@flygoat.com \
    --to=jiaxun.yang@flygoat.com \
    --cc=axboe@kernel.dk \
    --cc=bhelgaas@google.com \
    --cc=chenhc@lemote.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lixuefeng@loongson.cn \
    --cc=tsbogend@alpha.franken.de \
    --cc=yangtiezhu@loongson.cn \
    /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).