Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9B10C4338F for ; Thu, 19 Aug 2021 03:13:42 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 24AA461100 for ; Thu, 19 Aug 2021 03:13:42 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 24AA461100 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3BB1182DBC; Thu, 19 Aug 2021 05:13:28 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 41F3F82E68; Thu, 19 Aug 2021 05:12:59 +0200 (CEST) Received: from mail-qt1-f177.google.com (mail-qt1-f177.google.com [209.85.160.177]) (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 64E5D82BCE for ; Thu, 19 Aug 2021 05:12:51 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tom.rini@gmail.com Received: by mail-qt1-f177.google.com with SMTP id e15so3438625qtx.1 for ; Wed, 18 Aug 2021 20:12:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=B6l9Dnx++aX+4pews/jnBCCYLBxAZxSLIdLPGf1Z6qI=; b=ddU+pqkprPqxW4GoJOZkAuiXxZfeC6neT6Ta633NS//aLi8jaWyITQg3eP3HsIvrK4 vw8OAydsMzjQAR7AGDHUbTU/t/uYF74WKFpElqnBNm/CKGzovDEmecmqNdgl6jVwNI61 M0H66JoZFUPtqFxSnPdzrgk2STWD9gRU3Hl2kKF40lkM5Mf9Ob/l/6l4g49poCMBoAr3 CLszySjsEKiySBRkFJajWarYY6Nc51V03/5CBKwXqNSIEO15pPPFN1+xIw9pLjwoNzaO TKYBvq4vBeih1J7+p+W76r7lu/55tg0AD2i+H9swbd1P57a7PhA41tuo7+M2b1mCi/+O Z2ww== X-Gm-Message-State: AOAM5314SHo0N53KOtfvsq4Cil7mXV6lId5SuPpYDDXP6NFtzMfU5RHf 9MPG6WUMkjnD8UjrAqjkrfQ1IApcdNPW X-Google-Smtp-Source: ABdhPJztPSyFBmyN2AhilDQFmqr142vptZKKac68/3s1QgCstDkjV0YeQ9h5o8OgEdsD5vqAcZO6Ew== X-Received: by 2002:ac8:7352:: with SMTP id q18mr10953659qtp.5.1629342769950; Wed, 18 Aug 2021 20:12:49 -0700 (PDT) Received: from bill-the-cat.lan (2603-6081-7b01-cbda-c592-d3ae-4d6b-6c5e.res6.spectrum.com. [2603:6081:7b01:cbda:c592:d3ae:4d6b:6c5e]) by smtp.gmail.com with ESMTPSA id h140sm984045qke.112.2021.08.18.20.12.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Aug 2021 20:12:49 -0700 (PDT) From: Tom Rini To: u-boot@lists.denx.de Subject: [PATCH 04/16] am335x: Drop non-DM_I2C code Date: Wed, 18 Aug 2021 23:12:27 -0400 Message-Id: <20210819031239.19772-5-trini@konsulko.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210819031239.19772-1-trini@konsulko.com> References: <20210817220009.22721-1-trini@konsulko.com> <20210819031239.19772-1-trini@konsulko.com> X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean On this platform, we have DM_I2C and SPL_DM_I2C always enabled. Remove legacy options. Signed-off-by: Tom Rini --- board/ti/am335x/board.c | 18 ------------------ board/ti/am335x/mux.c | 9 --------- 2 files changed, 27 deletions(-) diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c index 2e4f3d102b7d..0e209a5a72d9 100644 --- a/board/ti/am335x/board.c +++ b/board/ti/am335x/board.c @@ -79,10 +79,6 @@ void do_board_detect(void) { enable_i2c0_pin_mux(); enable_i2c2_pin_mux(); -#if !CONFIG_IS_ENABLED(DM_I2C) - i2c_init(CONFIG_SYS_OMAP24_I2C_SPEED, CONFIG_SYS_OMAP24_I2C_SLAVE); - i2c_init(CONFIG_SYS_OMAP24_I2C_SPEED2, CONFIG_SYS_OMAP24_I2C_SLAVE2); -#endif if (ti_i2c_eeprom_am_get(CONFIG_EEPROM_BUS_ADDRESS, CONFIG_EEPROM_CHIP_ADDRESS)) printf("ti_i2c_eeprom_init failed\n"); @@ -339,13 +335,8 @@ static void scale_vcores_bone(int freq) if (board_is_bone() && !strncmp(board_ti_get_rev(), "00A1", 4)) return; -#if !CONFIG_IS_ENABLED(DM_I2C) - if (i2c_probe(TPS65217_CHIP_PM)) - return; -#else if (power_tps65217_init(0)) return; -#endif /* @@ -438,13 +429,8 @@ void scale_vcores_generic(int freq) * 1.10V. For MPU voltage we need to switch based on * the frequency we are running at. */ -#if !CONFIG_IS_ENABLED(DM_I2C) - if (i2c_probe(TPS65910_CTRL_I2C_ADDR)) - return; -#else if (power_tps65910_init(0)) return; -#endif /* * Depending on MPU clock and PG we will need a different * VDD to drive at that speed. @@ -472,10 +458,6 @@ void gpi2c_init(void) if (first_time) { enable_i2c0_pin_mux(); -#if !CONFIG_IS_ENABLED(DM_I2C) - i2c_init(CONFIG_SYS_OMAP24_I2C_SPEED, - CONFIG_SYS_OMAP24_I2C_SLAVE); -#endif first_time = false; } } diff --git a/board/ti/am335x/mux.c b/board/ti/am335x/mux.c index e450ff64d87b..fed737fa099a 100644 --- a/board/ti/am335x/mux.c +++ b/board/ti/am335x/mux.c @@ -345,14 +345,6 @@ void enable_i2c2_pin_mux(void) static unsigned short detect_daughter_board_profile(void) { unsigned short val; - -#if !CONFIG_IS_ENABLED(DM_I2C) - if (i2c_probe(I2C_CPLD_ADDR)) - return PROFILE_NONE; - - if (i2c_read(I2C_CPLD_ADDR, CFG_REG, 1, (unsigned char *)(&val), 2)) - return PROFILE_NONE; -#else struct udevice *dev = NULL; int rc; @@ -362,7 +354,6 @@ static unsigned short detect_daughter_board_profile(void) rc = dm_i2c_read(dev, CFG_REG, (unsigned char *)(&val), 2); if (rc) return PROFILE_NONE; -#endif return (1 << (val & PROFILE_MASK)); } -- 2.17.1