Received: by 10.223.185.116 with SMTP id b49csp1133752wrg; Wed, 14 Feb 2018 12:08:36 -0800 (PST) X-Google-Smtp-Source: AH8x2270AVMQprgGkLBt6l+N0l4dec5sl2BgsYZnDdTLn7hMt/5QsE/a717qQhM8Gt1NCscA4iPC X-Received: by 10.99.56.7 with SMTP id f7mr171959pga.114.1518638916191; Wed, 14 Feb 2018 12:08:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518638916; cv=none; d=google.com; s=arc-20160816; b=LpNvz/QAdrgfH4lu4+Xt02S4ZfQTTGPSFkIb7+YqKLtCWXxrT4iiiAIH1hitEEbVkg /SId89jtpXhWNtinuPbpZfOk+AuDYXK1ieAnYjLyIEE/3BvaYU/HHuJqs4deXuHpGSKA bMQnymBJUMWcuzl3Y902NeknAYFj60Idqtk+vGQj+n7FlBdm6ywy9CWYItKdU/Bnc7c9 VIk575pYNaobxBegehhJimrmgVAGngKZkWr5imBY9XEBkqd3ol2EzEf7NdggGCSPAIDU NNteufnVS5JuiAw0z96GKzsF3ayffhGQBONgeRwfHEcIatoHlRbB3fq3Nn2i/jC0svgZ 6OLg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dmarc-filter:arc-authentication-results; bh=bRVKqsVcPI4lDUpL0bRbVr/eCvyXqAeB3e4DC4mG7V4=; b=E92vn4h27TiLbI/aDo7xr06LuprR4ZMDfUQT14i7+yddrUyE6knVXr2mLqiGIAlJ/9 wRyjXw+2uj20VUxnUd5fkzHEufD9w1ClcSh0jIKMFp9GPgiV1gR1SlFXArA0L9t+NXe7 BCCSrVgZqeunF5t/75Wa4SpTyLATuREILupfRd4h/sKyvtKlcnHth4fsNuzQe4gLfFJf blYMwUsKBkW0Wh6ttM2nkbiYQvjqRpUI3luvB3Z7J4gN3SMJOueBuzsTVwRru08Hi+Yw Pikvtxzz46yfGBJRdc+r/3xJg36LNiMAwBgnUbmLHNutI6MZzFXNXFbQLC3gTVxxi7M9 /7rg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a71si174833pge.378.2018.02.14.12.08.21; Wed, 14 Feb 2018 12:08:36 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1032994AbeBNQvm (ORCPT + 99 others); Wed, 14 Feb 2018 11:51:42 -0500 Received: from mail.kernel.org ([198.145.29.99]:44940 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1032793AbeBNQvk (ORCPT ); Wed, 14 Feb 2018 11:51:40 -0500 Received: from saruman (jahogan.plus.com [212.159.75.221]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E5F922177D; Wed, 14 Feb 2018 16:51:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E5F922177D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=jhogan@kernel.org Date: Wed, 14 Feb 2018 16:51:35 +0000 From: James Hogan To: Alexandre Belloni Cc: Ralf Baechle , linux-mips@linux-mips.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 4/8] MIPS: mscc: Add initial support for Microsemi MIPS SoCs Message-ID: <20180214165135.GC3986@saruman> References: <20180116101240.5393-1-alexandre.belloni@free-electrons.com> <20180116101240.5393-5-alexandre.belloni@free-electrons.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="TiqCXmo5T1hvSQQg" Content-Disposition: inline In-Reply-To: <20180116101240.5393-5-alexandre.belloni@free-electrons.com> User-Agent: Mutt/1.7.2 (2016-11-26) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --TiqCXmo5T1hvSQQg Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 16, 2018 at 11:12:36AM +0100, Alexandre Belloni wrote: > diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig > index 350a990fc719..a9db028a0338 100644 > --- a/arch/mips/Kconfig > +++ b/arch/mips/Kconfig > @@ -527,6 +527,30 @@ config MIPS_MALTA > This enables support for the MIPS Technologies Malta evaluation > board. > =20 > +config MSCC_OCELOT > + bool "Microsemi Ocelot architecture" > + select BOOT_RAW > + select CEVT_R4K > + select CSRC_R4K > + select IRQ_MIPS_CPU > + select DMA_NONCOHERENT > + select SYS_HAS_CPU_MIPS32_R2 > + select SYS_SUPPORTS_32BIT_KERNEL > + select SYS_SUPPORTS_BIG_ENDIAN > + select SYS_SUPPORTS_LITTLE_ENDIAN > + select SYS_HAS_EARLY_PRINTK > + select USE_GENERIC_EARLY_PRINTK_8250 > + select MSCC_OCELOT_IRQ > + select PINCTRL > + select GPIOLIB > + select COMMON_CLK > + select USE_OF > + select BUILTIN_DTB > + select LIBFDT Please sort alphanumerically. > + help > + This enables support for the Microsemi Ocelot architecture. > + It builds a generic DT-based kernel image. > + > config MACH_PIC32 > bool "Microchip PIC32 Family" > help =2E.. > diff --git a/arch/mips/mscc/Platform b/arch/mips/mscc/Platform > new file mode 100644 > index 000000000000..9ae874c8f136 > --- /dev/null > +++ b/arch/mips/mscc/Platform > @@ -0,0 +1,12 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR MIT) > +# > +# Microsemi MIPS SoC support > +# > +# License: Dual MIT/GPL > +# Copyright (c) 2017 Microsemi Corporation > + > +# > +# Microsemi Ocelot board(s) > +# > +platform-$(CONFIG_MSCC_OCELOT) +=3D mscc/ Please use tabs to align > +load-$(CONFIG_MSCC_OCELOT) +=3D 0x80100000 Please drop the space after the tab. > diff --git a/arch/mips/mscc/setup.c b/arch/mips/mscc/setup.c > new file mode 100644 > index 000000000000..77803edd7bfd > --- /dev/null > +++ b/arch/mips/mscc/setup.c > @@ -0,0 +1,106 @@ =2E.. > + > +#include > +#include > +#include > +#include Please sort these includes alphanumerically if possible. > + > +static void __init ocelot_earlyprintk_init(void) > +{ > + void __iomem *uart_base; > + > + uart_base =3D ioremap_nocache(0x70100000, 0x0f); Maybe these hex literals (the address at least) can use #defines. 0xf is an odd size when the 2 below indicates 32-bit registers. > + setup_8250_early_printk_port((unsigned long)uart_base, 2, 50000); > +} =2E.. > +extern void (*late_time_init)(void); This is already declared in linux/init.h which you include, so I think you can drop it. > +void __init device_tree_init(void) > +{ > + if (!initial_boot_params) > + return; I think flatten_and_copy_device_tree() already checks this (with a warning), so this could be dropped. Cheers James --TiqCXmo5T1hvSQQg Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEd80NauSabkiESfLYbAtpk944dnoFAlqEaRYACgkQbAtpk944 dnoUmRAAmSAfy9w+IUOo/+i9DvxR2NNyykOd/IMT+Gu60Mv9MTWo0YsgFNfAYvMT LSov9zXoF4z7cC0BmWU8OJ5ai7NjtO0fQyKuLswUlWWVL8Nh3ez9TjwX2VgrJ6+6 4bvHpoJwDx48P9TyVPpk36hm7WpDGpoCFsxDkNe7PT5FkKLWlVh0io/oFCRCmEdC c7dihRSXx/wGTSqvPGMzoC3FQQ6xJrQ9SsvpBBf34zcx3w9ibFeC3uwwg3D5YIeJ mSLvD53vdkfgmRaBaDH6k2c40kSHDQQOrXTa1d4tobUvOwebiCF5xLsn+pW6UL+J bBFOPaoxOw0do42ph8gbHQ2Zr3PxldQpkU3TclMODWFFYNsAm4gCbJZEscf9z0kT IpeQQakRGaTeHpD2Rf3zs10PK7ARFKJV06ZfB4Ca4yuck/AJXVViVyITGkz8TgjF sDbnSe443g46EQu7xegrRykx1iRhcAQc+Kdwb1ynFQzTQrZQy+9M24RffFGgyYyo ddCWjr8nogQCVpXhX3vsVJHZQ9uh+7aFlqOLokIovHhmkRizbDcG9mANTzyPFKAC xmsIa6ijLi+cgWILwEhiN317p/pEepPDgqRltas7MDstHJK+PzRTr4rRtF30RyfB pibSrIBEbhde8EqN5W0pTfsTx/FGmLeq0s1G+7vZc9v8Gw4mh7I= =a6Jb -----END PGP SIGNATURE----- --TiqCXmo5T1hvSQQg--