From patchwork Tue Jul 21 15:05:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 1539 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pl1-f198.google.com (mail-pl1-f198.google.com [209.85.214.198]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id E20893F08B for ; Tue, 21 Jul 2020 17:06:20 +0200 (CEST) Received: by mail-pl1-f198.google.com with SMTP id p4sf12683488pls.16 for ; Tue, 21 Jul 2020 08:06:20 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1595343979; cv=pass; d=google.com; s=arc-20160816; b=ti1gZTr8+CHQK+MeGta/K6z17AUWvvGLscDK8dxjhC/fWxjFziIY6Oedx5u9KstCUr AmhduJFIkuiFPMfMP+ajB9ULy2JlRIICdEz9Mnc257/Lt1PU4c+YLIleSre4KnE/1uCJ Oxbrev+0fXgx/CXGB/s08CGKgNgFDt9lUwDfB1R+0cj371LFRXYlr/I5VZiT44uG8Yq+ kQWZ/o1U3JUC1lHDnmTWNV3CbbWZWHmscmKAvm0svC0S/Qw0qGgZTsSPurhhk/jzsOvs 3qckwcI7L099jqdCRC09F6bazsjz0iosRydfzLZzK8uCUq7iCb6IYITd02aHCGkTIClx GTcA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:message-id:date:subject:cc:to :from:dkim-signature; bh=QSSLni71RvPpHspTrcQIZPQ03C02FaZlGJg2PvoS1xI=; b=w4bDqxKl3aSXnI31dOA+nWHhTWBot9S/6A35FWVAhzq4/E4iuliAQcknE7buZZBx8X Q4cqFEkgZEOWRB3+apazRqVHORCqQsE1P28/IgmMAHsJqIDBcXbHnY2JOR4BH2H9TBx6 5FuGg2FPUOz4zYFRfy0OGL/AFZFKaj99CivnrfuZ9XHndNvZZ3VVCZ3d5lAs1fUIdKJY vdHR/eGtJqo06eQCzgzmYWUVt64RgIiE2Hvj61o7ypFK9R5bFFXjkM6e94rjGLf/kAhN vHE96flaATXjn9Z8xA3l+Akx+5vM3vwWMGbKX57ozcfdSFsloIwiLYZ3nAU+vz0lA3CD bpwQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=QIgzVzii; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=QSSLni71RvPpHspTrcQIZPQ03C02FaZlGJg2PvoS1xI=; b=c0R+fWBZfcybss5evcX1Z6wNa/3SjvJ4Ds6KCjAsizEsi3GBgudNMgX1trOi4XxnqL vmxBudU3V4kssZhxyn9B5zvZdrXUrEsodpP2F9jv+DwIutjbZtB/oDU2nzKA2CzPoJyP yH4yxm4ggik/A4+Cm/fwXf+Ul47jeOMJYX020= 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:mime-version :x-original-sender:x-original-authentication-results:precedence :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help :list-archive:list-unsubscribe; bh=QSSLni71RvPpHspTrcQIZPQ03C02FaZlGJg2PvoS1xI=; b=s4lxLvai+36K2jlGcsAzhsXS581jHOOs0YjB0XsXunz1ahxxlxr0Q8DK5oqF4EbMRv FR98dPbodC1ktElZDhoep4V7ZsatDZCEu47ga8PPG7o56/tWkz6y8gq6EvdiDmyUoHxg 4wA37EabbR/5YnsdNCg2tvX9fZm2TrQbatRl1Ox2zifaFhh1gnLJjPaXsPvD/2QhDo6w olz0XtSsiM9sDGrrc32uRWXJusDeLSfxvn5mnbNkIkP29BQb5SD6YJiQtk3eWwUkBwTz 36SmKNDTxqGB6zKVnjjeX8bsPL8Whgp7MjyPBVVP4Wasl/Mh1V3YjoLXuU90ZEeC9niu FlLg== X-Gm-Message-State: AOAM533a3kDMpYCbx3m0I+y0otQ2HIpIWCMFlygUyrH9gOjHgZEqBi4x FfZKd9a9h9TQEfCbUMRtJA9vK0KD X-Google-Smtp-Source: ABdhPJyTRQAWpe0mK1m4pBfDKzuio8vuRuvEtaezREf9eLxjKO24Y3wFx9Kj5j4J0Z/JzaDpI/9oeA== X-Received: by 2002:a63:fc43:: with SMTP id r3mr23218262pgk.423.1595343978603; Tue, 21 Jul 2020 08:06:18 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a63:f450:: with SMTP id p16ls2907912pgk.5.gmail; Tue, 21 Jul 2020 08:06:18 -0700 (PDT) X-Received: by 2002:a65:6416:: with SMTP id a22mr22180024pgv.392.1595343978051; Tue, 21 Jul 2020 08:06:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595343978; cv=none; d=google.com; s=arc-20160816; b=enpcF+sdjzabpV8Q1WVkk3rsE6dMjY4fCqrTCh7/HZ5Fwjd1G3/ZFYfa8BNwtSTXdi AlyR1ycUYv6mYHFUYreJ1WHSs/DLGMyZcqDTEo2p7Iqcl0XLdO3QeQqOHtHqlWaFo4VS ghH7vixL4Dh5OCi71bHpsjluUCTnn6ToiAycBYmo5Q/rCZaBfSBEHLQqMF34HBvKj6ko Sy0QCs8QWWuqlQgd/dxz/t91ZudiPiNJEqDfIzzdTUN/RkWfblYaVxxar7EiatLekkiy s8v1dTvDEhArU2hI6kZoywQxo/DreaPFZc2GGfOldjnaRmKf455nZ4ULjWAvQHBfqBpm TA3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=/AvIuTmocjcmT91LwiJP4JLrRgbUU13zO/dEn3F4Wwo=; b=Y+yeZrEDWox2D5nThZRkPVyaiK2xgZ6NRG5Qh1LGg+7hH/qMhXDCt9bZxT420cV2Dv jbecgptVW0UcIavwnMJy7FpF/sUs6uMpdUzckiIEYk9zMLnpODtwnqCrRtnO+WPM4xg8 3wlWMvwdAKxekRWQPu8/dYSyVxVf2uN0bg47C4cRX3FeGMnqSvVlGq99WVQGb220uKwN Qg4pk1rQfPWusZHv1yaGpA3SWVx9BBjcezOtVsuxmC+qoARMeA4ZZS9kh3+qcBMp5omY 6Ju3E/Iz9/v5ZCJnF1Zj5bCOus/iuDxEEMhXPFFpv/C5raPEjDdiyfPF9xKJrn9H8J9F 00uw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=QIgzVzii; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id t138sor18737270pfc.101.2020.07.21.08.06.17 for (Google Transport Security); Tue, 21 Jul 2020 08:06:17 -0700 (PDT) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; X-Received: by 2002:a62:4e44:: with SMTP id c65mr24125405pfb.283.1595343976708; Tue, 21 Jul 2020 08:06:16 -0700 (PDT) Received: from localhost.localdomain ([2405:201:c809:c7d5:3df7:ef76:b2b5:fa14]) by smtp.gmail.com with ESMTPSA id h9sm20671276pfk.155.2020.07.21.08.06.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Jul 2020 08:06:15 -0700 (PDT) From: Jagan Teki To: Kever Yang , Philipp Tomsich , Simon Glass Cc: Suniel Mahesh , U-Boot-Denx , linux-rockchip@lists.infradead.org, linux-amarula , Jagan Teki Subject: [PATCH v6 0/5] rockchip: roc-rk3399-pc: Custom SPL Date: Tue, 21 Jul 2020 20:35:59 +0530 Message-Id: <20200721150604.35410-1-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=QIgzVzii; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This series supports custom initialization code required for roc-rk3399-pc board on SPL stage. Now this series is well mature code handling to add custom spl_board_init code parts. roc-rk3399-pc would require custom leds initialization based on user intervention of the power key. This code handles the user intervention via SPI environment variable. If someone or production systems wants this feature then 'pwr_key' has to be set otherwise it is normal like other rk3399 boards in Mainline. Changes for v6: - use spl board init code for led_setup Changes for v5: - drop banner changes - add code changes in roc-pc-rk3399.c Changes for v4: - enable SPL_BOARD_INIT in all platforms Changes for v3: - support leds on SPL - support env 'pwr_key' Jagan Teki (5): rockchip: rk3399: Add weak led_setup() rockchip: roc-rk3399-pc: Add custom led_setup() rockchip: Don't clear the reset status reg rockchip: Separate the reset cause from display cpuinfo rockchip: roc-rk3399-pc: Set LED only during POR and pwr_key=y arch/arm/include/asm/arch-rockchip/cru.h | 3 +- arch/arm/mach-rockchip/Makefile | 5 ++- arch/arm/mach-rockchip/cpu-info.c | 26 ++++++----- arch/arm/mach-rockchip/rk3399/rk3399.c | 6 +++ arch/arm/mach-rockchip/tpl.c | 7 --- board/firefly/roc-pc-rk3399/roc-pc-rk3399.c | 48 +++++++++++++++++---- configs/roc-pc-mezzanine-rk3399_defconfig | 6 ++- configs/roc-pc-rk3399_defconfig | 6 ++- 8 files changed, 71 insertions(+), 36 deletions(-)