From patchwork Mon Oct 15 16:28:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 10642175 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9CB3018BC for ; Mon, 15 Oct 2018 16:31:49 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8A66B29AEA for ; Mon, 15 Oct 2018 16:31:49 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7DEF129C48; Mon, 15 Oct 2018 16:31:49 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D468C29AEA for ; Mon, 15 Oct 2018 16:31:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=YV1AtyLk1WOkYky4OZdRXVi82jCcTnIVtClB8pEh6BA=; b=O7nufl+37HUkruv1GPzBfXchx/ DYVYZlh3/hlUzprRClExKTX1l5OB1r8ymeSeso/IAe7wXWBy8pIYlWcn+absJi0fjrtifCE8PD0ov JR7AGzOMKxdoUZ2JxBk9Rg6AFHkYGk0+A9oEjtukZ70O4iPvV0RBOWx9DZu8qJBLslLMzauwvGFtV glGNXk4LnCvhV5wKpv2EbSnCl/xBfcQBoFuasS6sjSdRyIoP0mMsdxyhdg6iCo/MY48w+oJrc/+96 +OWHvqhlcplaoy9DQDbgEPf4Y8DdWSDNowAVANzBujKJtHo3a5Ah60OJcaDgeJ6NPynOCylh4OCMe poMAPYIQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gC5mH-0006R4-9c; Mon, 15 Oct 2018 16:31:33 +0000 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gC5jf-00044E-TL for linux-arm-kernel@lists.infradead.org; Mon, 15 Oct 2018 16:30:40 +0000 Received: by mail-wr1-x444.google.com with SMTP id n1-v6so22083829wrt.10 for ; Mon, 15 Oct 2018 09:28:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=eXycmWv4/YSgM20PwhnetExzSgEMuwDfaJY/spL27UM=; b=f4PM9RPrtH39FeI9DhSFAPxrqe+xpB8dyZCE1gAXktR49AOU41v77ohMNmG3zka5IJ ZgARpJm4Gkj0orM7sV/P3A2pLhhvF7yXsWqa4LHkg2vEZnv/vcnibn6CgJ5iU08IXtte c1K2AC7jtipTPlS+nx8yFl4Yos+ZlJLaB0jKn5AtA+2e0d22kDi8qlwdcCs4mTAwu3eg rC+Cs2Lr9JnJLsiLiCRpojVACEjN+r17Rthn0+lOrutjjMhyscTZHMi7Nu2vfwpOVRGN wbqPUFGi5SBRSBZnEI2PGiOSI+K76Ft/yi6h4A2wOiLEkpNgqTmY4lQhpovG+9wwkYkj qLXQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=eXycmWv4/YSgM20PwhnetExzSgEMuwDfaJY/spL27UM=; b=BtXeYn81a1K7Afy6aUpSwpCv9UE+BgXtgtl6+rybpt+EymYs6TTq9Pcf5BYd0Ffig0 iup2VuEgzJ4lujUU/RsICFcaC4Y1OSIFub/cLKfSiQrBfgFic/5R8EBuFodGOt0ZAjo5 KpYF/qzsQ/+Xm3sfEiwQOkj5pw6j0xaC3e/+7a2gikbqS7jY/Vh6eMuqZP1dOk6woarc 3qZH2d/2B/yuYYrlP1yFPM7Lijuw2+/5jMv/UnubZYe6olOps983HRvh6gWVCDpZG1Ks Oc1BxvfEN8Xo/pw4i4vus2o3dleqJ9IkGRbvHSCx7xZVUN3gDzrVH6Ff74KAmiuKJ508 5wcw== X-Gm-Message-State: ABuFfogVW4+Bg/EJZLPaMVmUwCJ4X/rJ7a0adCoOQRsIjT76cB0j3ihg nKbu6a1+PG4QW2sL3fAMlsJ0EQ== X-Google-Smtp-Source: ACcGV61xlLh0dbNUWNrramcTqd55VK8KDy2MzkW/JhpY/Os7vOCH1MWsB6QGNv+BOlwWBOBgbcdKWQ== X-Received: by 2002:a5d:4ec8:: with SMTP id s8-v6mr14144300wrv.32.1539620920122; Mon, 15 Oct 2018 09:28:40 -0700 (PDT) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id c8-v6sm14045926wrb.6.2018.10.15.09.28.39 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 15 Oct 2018 09:28:39 -0700 (PDT) From: Jerome Brunet To: Kevin Hilman , Carlo Caione Subject: [PATCH 1/2] arm64: dts: meson: fix reserve memory regions Date: Mon, 15 Oct 2018 18:28:32 +0200 Message-Id: <20181015162833.7544-2-jbrunet@baylibre.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181015162833.7544-1-jbrunet@baylibre.com> References: <20181015162833.7544-1-jbrunet@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181015_092852_039794_12D8B345 X-CRM114-Status: GOOD ( 16.68 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Neil Armstrong , linux-kernel@vger.kernel.org, stable@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org, Jerome Brunet MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Since commit 50d7ba36b916 ("arm64: export memblock_reserve()d regions via /proc/iomem") was merged Amlogic's boards using mainline u-boot started showing the following warning: WARNING: CPU: 0 PID: 1 at arch/arm64/kernel/setup.c:271 reserve_memblock_reserved_regions+0xd8/0x144 Modules linked in: CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.19.0-rc7-00263-g385684b3eb27-dirty #254 pstate: 40000005 (nZcv daif -PAN -UAO) pc : reserve_memblock_reserved_regions+0xd8/0x144 lr : reserve_memblock_reserved_regions+0xd0/0x144 [...] This is due to u-boot setting some /reservedmem/ region while our dts declares reserved memory on the same region with no-map. The conflict produce the warning. This is fixed by using /reservedmem/ in our dts as well, which is probably something we should have done from the beginning. Cc: stable@vger.kernel.org Cc: Neil Armstrong Signed-off-by: Jerome Brunet --- Hi Kevin, I would have liked to put a Fixes tag above but I could not figure out which commit to pick, considering how much we changed those regions in the past. If you have suggestion, I'll be happy to repost this patch. If you prefer, feel free to amend this patch directly. Cheers Jerome arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 24 +++++-------------- arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 27 ++++++++-------------- 2 files changed, 15 insertions(+), 36 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi b/arch/arm64/boot/dts/amlogic/meson-axg.dtsi index 178d8e8c56b8..06a06f11f114 100644 --- a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-axg.dtsi @@ -13,6 +13,12 @@ #include #include +/* 16 MiB reserved for Hardware ROM Firmware */ +/memreserve/ 0x0 0x1000000; + +/* 3 MiB reserved for ARM Trusted Firmware (BL31) */ +/memreserve/ 0x05000000 0x300000; + / { compatible = "amlogic,meson-axg"; @@ -115,24 +121,6 @@ method = "smc"; }; - reserved-memory { - #address-cells = <2>; - #size-cells = <2>; - ranges; - - /* 16 MiB reserved for Hardware ROM Firmware */ - hwrom_reserved: hwrom@0 { - reg = <0x0 0x0 0x0 0x1000000>; - no-map; - }; - - /* Alternate 3 MiB reserved for ARM Trusted Firmware (BL31) */ - secmon_reserved: secmon@5000000 { - reg = <0x0 0x05000000 0x0 0x300000>; - no-map; - }; - }; - soc { compatible = "simple-bus"; #address-cells = <2>; diff --git a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi index 676a995fb912..23e879b29b1e 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi @@ -13,6 +13,15 @@ #include #include +/* 16 MiB reserved for Hardware ROM Firmware */ +/memreserve/ 0x0 0x1000000; + +/* 2 MiB reserved for ARM Trusted Firmware (BL31) */ +/memreserve/ 0x10000000 0x200000; + +/* Alternate 3 MiB reserved for ARM Trusted Firmware (BL31) */ +/memreserve/ 0x05000000 0x300000; + / { interrupt-parent = <&gic>; #address-cells = <2>; @@ -23,24 +32,6 @@ #size-cells = <2>; ranges; - /* 16 MiB reserved for Hardware ROM Firmware */ - hwrom_reserved: hwrom@0 { - reg = <0x0 0x0 0x0 0x1000000>; - no-map; - }; - - /* 2 MiB reserved for ARM Trusted Firmware (BL31) */ - secmon_reserved: secmon@10000000 { - reg = <0x0 0x10000000 0x0 0x200000>; - no-map; - }; - - /* Alternate 3 MiB reserved for ARM Trusted Firmware (BL31) */ - secmon_reserved_alt: secmon@5000000 { - reg = <0x0 0x05000000 0x0 0x300000>; - no-map; - }; - linux,cma { compatible = "shared-dma-pool"; reusable; From patchwork Mon Oct 15 16:28:33 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 10642167 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9FF4214E2 for ; Mon, 15 Oct 2018 16:29:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8F27429938 for ; Mon, 15 Oct 2018 16:29:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 833282994B; Mon, 15 Oct 2018 16:29:10 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DF50A29938 for ; Mon, 15 Oct 2018 16:29:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=Wy62BRFlVn4MWQZd1C8CeMPF32SkVUP+UnN7j3tihFY=; b=nPW8FeygEYQbKGKqbc3mzt6D0y vHrxmjletBM0btgqLucGT29GuFaQ7gtIvVZJ7Bt2RDVYzziefYz5tJHhQ3bnhSFSB9xt5EyLCnYsx gMzrzJWWIEMlZlu2RKx1rX1ZHNH445h7TrL2SjMhsBDdUg9T77oz4YOnUM6bu8JUJcNEdQjByurir r14wfl4sQFHGXIQa3LSN2PaZKxmalyeATkT69/2m5c2GbNBkdqUm6hD1s5uz2njIhqellKHlWDPyK bf3wOAcVv7ky2C6nusr02/dM7VLiQ6SBYsNcEH5jwIUZr/NlhV+KTXRWye2giAUf3ks69wbPXK57a UvJ/L87A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gC5js-00048R-7D; Mon, 15 Oct 2018 16:29:04 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gC5jn-000482-Ug for linux-arm-kernel@bombadil.infradead.org; Mon, 15 Oct 2018 16:28:59 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=+DyCxkj+D/g7NE4kKGpBjPKPVkzXiIpmqo3AIhGxDvM=; b=RuW2W1sdFRMuYxtnCu3yW0Ohw ba7ceM6+vZ+ePzDQhGEsr/oTHQItvTbX8lA4k0e3XYwsx2U+oqVRzxfpiu5MLu52c7xRAtabp/WrI dYzPNBDtY4u75ZZKwRL7C+RfLqDk/3a64ZFoxFdpvVG1optVhxja1eZUSHBJeDDlVOQ2gFSBE0fdQ 8YQnL1GAEy2kccg7WfryxrKERGttiL4Wd38WRltciuaK8iw2yDCuj9EdYymOgf7NweRHH6z4qPa6G 1Xzwi+bH5EJJ8dB4Dd3KaEBwdU5/TxZfoJUHl88v1n3cqNc5jnvNHDTG5rAXbefPbH3TGoUE7LiHj WjR4ycKqg==; Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gC5jl-0001hn-7U for linux-arm-kernel@lists.infradead.org; Mon, 15 Oct 2018 16:28:58 +0000 Received: by mail-wm1-x341.google.com with SMTP id 143-v6so19443710wmf.1 for ; Mon, 15 Oct 2018 09:28:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=+DyCxkj+D/g7NE4kKGpBjPKPVkzXiIpmqo3AIhGxDvM=; b=Q1xQdC63nkv6Lh/d80Fpmmwk8rPAcqvT2R4JV4asJhxrT5+680VrX463iwZQPcc3bN HHrKEfRhP6Yjm2s8AVXSpkqdtoaDoE9Bl1RJkr+rAfjEwneBrFxIhU50+67dmlpIs+5+ 69BZ8FIQd4k+aO0pPqxtmaIqbYjRRT5mJDsxnOmzXGu5TwLzjCRn5FI5d3C/kmkEj8II 25ik4hFFAIaf0B/Js+N6nx1Owe2/JlNNTlUtxtd6i5Ua2Wbh5qOPmFNIhJ+i0k7NYcF2 vs9mczhvEV4BniFaFakU1bvvjMDR4019JC3L79E15NGuEgKGlhiAdQkK+KjyAL5pWfRq +w6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=+DyCxkj+D/g7NE4kKGpBjPKPVkzXiIpmqo3AIhGxDvM=; b=RagskCC8+AqH/ZPohkGHPHrt1nqyOTsdhym8cSqYK3sxzvhBJ20zHQNVB4IMl8UOXp V3MRHWXBGMYYZMZhU5a8hVhXuOAJ+HGAIzSeEuKSopwYhjquoliZTsVOjBjao8EY+yRV paJnbSbbHXTcXzv+uJoB7sBTUx/9Cy/+os1m6vg4hocLKoNlM8ceXlsGDme6ONWVbt8R gIX1WXSS3U/U4JM0ctKy7y9XhO8MU/8kdjCAAherTeODoWl3x2URQkLJQi+WRsWz5Xpe 9wlmoH6SRRUUNFFwAdqZaOuHZrruGhkaDnyUElmoU8Ygp77UGseQN8/59xnmi3jDCwdN zlHg== X-Gm-Message-State: ABuFfogdj98K8A0jI/zaMt3bGSsl5M25ieOYmE6LoxYESk9Zsyv1YOnm aVJx6je7RBuHKI9RoyVScXJmnQ== X-Google-Smtp-Source: ACcGV62HkoxUQ52H1Yx+hYWGE8YWRM+J61hf8qEgi6ROI98JdikzSqYHqzy7yNxJkTXhrgJ2D+6sjw== X-Received: by 2002:a1c:1dc8:: with SMTP id d191-v6mr13325599wmd.27.1539620921040; Mon, 15 Oct 2018 09:28:41 -0700 (PDT) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id c8-v6sm14045926wrb.6.2018.10.15.09.28.40 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 15 Oct 2018 09:28:40 -0700 (PDT) From: Jerome Brunet To: Kevin Hilman , Carlo Caione Subject: [PATCH 2/2] arm64: dts: meson-axg: drop FW reserved memory Date: Mon, 15 Oct 2018 18:28:33 +0200 Message-Id: <20181015162833.7544-3-jbrunet@baylibre.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181015162833.7544-1-jbrunet@baylibre.com> References: <20181015162833.7544-1-jbrunet@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181015_122857_286243_FE845DFD X-CRM114-Status: GOOD ( 12.99 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jerome Brunet MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The axg does not require the FW memory region for all we know. This seems to be something we carried for the gx family for no reason. Fixes: 9d59b708500f ("arm64: dts: meson-axg: add initial A113D SoC DT support") Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 3 --- 1 file changed, 3 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi b/arch/arm64/boot/dts/amlogic/meson-axg.dtsi index 06a06f11f114..d1beedc4fb0e 100644 --- a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-axg.dtsi @@ -13,9 +13,6 @@ #include #include -/* 16 MiB reserved for Hardware ROM Firmware */ -/memreserve/ 0x0 0x1000000; - /* 3 MiB reserved for ARM Trusted Firmware (BL31) */ /memreserve/ 0x05000000 0x300000;