Re: [PATCH 2/6] mips: Add N64 machine type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jan 08, 2021 at 09:04:34AM +0200, Lauri Kasanen wrote:
> On Thu, 7 Jan 2021 18:10:35 +0100
> Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx> wrote:
> 
> > 32BIT kernel don't compile, because you use TO_UNCAC which only
> > exists for 64bit kernels. One solution would be to use CKSEG1 to
> > convert from physical to an uncached address. But I'd prefer if
> > you add resources to your platform device and do ioremap in device
> > drivers. This way there is also no need to export the interrupt
> > defines outside.
> 
> :( Jiaxun told me to use TO_UNCAC because CKSEG1 was unclear to him...
> 
> I will change back to CKSEG1. ioremap seems much needless overhead.

ok, let me put it that way: Using ioremap is not a wish. To get your code
integrated use ioremap and platform resources. IMHO driver maintainers
will appreciate that as well. 

> > > +#define RCP_IRQ			MIPS_CPU_IRQ(2)
> > > +#define CART_IRQ		MIPS_CPU_IRQ(3)
> > > +#define PRENMI_IRQ		MIPS_CPU_IRQ(4)
> > > +#define RDBR_IRQ		MIPS_CPU_IRQ(5)
> > > +#define RDBW_IRQ		MIPS_CPU_IRQ(6)
> > > +#define TIMER_IRQ		MIPS_CPU_IRQ(7)
> >
> > and this IMHO also unsed, so no need to define it.
> 
> The sound driver uses the RCP IRQ; the machine-specific names are
> defined because they're much more clear.

you can keep the defines, but no need to have it in an #include when
you move it to n64/init.c. From there you pass it via platform irq
resource to drivers. Background is that I want to keep stuff in
mach-xxx at the bear minimum.

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]



[Index of Archives]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux