From patchwork Fri Jun 9 21:37:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam Edwards X-Patchwork-Id: 1793241 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20221208 header.b=rRmzu5I8; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QdDvf2BZXz20Vx for ; Sat, 10 Jun 2023 07:37:50 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 0208B846B7; Fri, 9 Jun 2023 23:37:45 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="rRmzu5I8"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4EC7A846B7; Fri, 9 Jun 2023 23:37:43 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-io1-xd35.google.com (mail-io1-xd35.google.com [IPv6:2607:f8b0:4864:20::d35]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 61F0A84677 for ; Fri, 9 Jun 2023 23:37:40 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=cfsworks@gmail.com Received: by mail-io1-xd35.google.com with SMTP id ca18e2360f4ac-77ac14ff51bso92565039f.3 for ; Fri, 09 Jun 2023 14:37:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686346658; x=1688938658; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=rTvJ0ryd6hxcjksSaY2FERJYw2GbwsjqKcVUF3Q9OxY=; b=rRmzu5I8EuVUKRWpl7Tk/3RDUl0BLA+2kr5kL1Cn78UaO06aOh6Tgua6jkq9DKhOWd lbmz0pu5DImh82VQHGZRmsmlp4okUpM3lCljeuBImVi3eSB0ZNYPqqPhBKlH13YXUjnZ bDXIiGjc8hLr/7Po/OUj6Sa6CvQDViQSximVDJjIVZll8pNjCDx7Sbb2XDK6tbNJ8+xI bjzU3PSiJee2LGRULUdg7r5zQjFAi+nRpAhVANm5Ck1pIvloUSqA3+c5Ago/r7Eu9S9+ dipA8OVX//IZnI4o1Nr1tPowHWElbWkBQH+PQ7J72aOLYda//7fYF3AC76B1bwwwg+kA CYWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686346658; x=1688938658; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=rTvJ0ryd6hxcjksSaY2FERJYw2GbwsjqKcVUF3Q9OxY=; b=RqSYES8txIs/5F+zuPTbMb4qy9je9IpyaptPq+EjT2sPHBlnPo/Wpr2+e23daTivyt uEgF5K7SeokVcKaxOtxD8clAaU794JQnIZBTNdOaxKIJrMtjN9blmeBHpIy7evL00Y1r GfRav4YDvV5yD8aPOsaTVguNnkFyip/SMpNRviGIk0DleuXeop7Ax2RcFWnI9hmkfO0m 8e62BskpQL5RQGJTfMtJrc7JQ8780WxyLKzOTLrhUUgngV7b3fzwu/KVwrkLBkGysFXs frVY4UAd+Ae4ec6Cjf/RwCYI+HUG1+6eAAj5/eHv657YOCRERVB5SHkFOmIOefQHXaaf VCwQ== X-Gm-Message-State: AC+VfDy2jBMyQZkvfycLbG8RBp7/HUxZYt/fYSSpcIreLSEb0RWio1jt V134XEFcNmLjn71RGUgWW9eUQZBvVt3SlwJC X-Google-Smtp-Source: ACHHUZ7BUdDRERv4zl0L+iHPCZGNcOPkFJMr/x6XoVhW8WUmrGm7OJCm9DH5trptuzBJr2XeZXDVTg== X-Received: by 2002:a5e:850d:0:b0:777:b64b:9b92 with SMTP id i13-20020a5e850d000000b00777b64b9b92mr2888463ioj.18.1686346658482; Fri, 09 Jun 2023 14:37:38 -0700 (PDT) Received: from celestia.nettie.lan ([2001:470:42c4:101:d264:8856:b4e9:a431]) by smtp.gmail.com with ESMTPSA id x6-20020a5e8306000000b0077a1b6f73b9sm1309187iom.41.2023.06.09.14.37.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 09 Jun 2023 14:37:38 -0700 (PDT) From: Sam Edwards X-Google-Original-From: Sam Edwards To: u-boot@lists.denx.de Cc: Andre Przywara , Jagan Teki , Marek Vasut , Sam Edwards Subject: [PATCH v2 0/2] sunxi, usb: Clean up SRAM initialization code Date: Fri, 9 Jun 2023 15:37:14 -0600 Message-Id: <20230609213716.107339-1-CFSworks@gmail.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean Hi list, This is the second version of cleaning up the SRAM initialization code in the musb-new variant for sunxis. Patch 1 ("only perform ... when necessary") has not changed since v1. Patch 2 has had the following changes: - Remove one-off bit/reg #defines, per feedback from Andre. - Switch to the Linux multiline comment style, per feedback from Andre. - Reword the commit message, since this change isn't as "speculative" as I had originally thought. - Perhaps controversially, introduce a `void *syscon_base;` under that TODO comment I mentioned before, to further invite somebody to "DO" it. :) Thank you once again for your continued efforts, Sam Sam Edwards (2): usb: musb-new: sunxi: only perform SRAM initialization when necessary usb: musb-new: sunxi: clarify the purpose of SRAM initialization drivers/usb/musb-new/sunxi.c | 43 ++++++++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 9 deletions(-)