Received: by 2002:a05:7412:f584:b0:e2:908c:2ebd with SMTP id eh4csp3312544rdb; Thu, 7 Sep 2023 10:41:10 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH5fdvCT6nB4WHddkYaE43wjys+fPN501dseyskRhZyOvwww0hVELYphhRD1REJBwjfIDwG X-Received: by 2002:a05:6402:42c5:b0:51e:34d8:f4c7 with SMTP id i5-20020a05640242c500b0051e34d8f4c7mr14874edc.2.1694108469803; Thu, 07 Sep 2023 10:41:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694108469; cv=none; d=google.com; s=arc-20160816; b=VnpVQnS/ycAQtS7YfkfvWD52wO8wiQLpG5TH2njcoUoALJjb3U08lMUs3aV9jB1UXw sihdjkKua1G+Fg/iqbeLEnrXuxfB2mB6+6zwlqElfSUaKo0vkJ+oSkgVySfPnwl0u5PP MBSHc4X8CaR8Z6epAvDbj9be4VhNmSV2ap97qAxbNTjspBHhzq8VP9FZswhguZuVR3o3 glzVpIDIayIDdz1bINauM/ZQ8QEtf/JIUuzrQnwmHUPQ+04QuwYK7d9/jMhOSQ4Pt3Zj pE+ibvdr5Ho5+8HivD5pvzKwTrvK3dO4CNcWjmK1RwCyXUS56WCNBbbL2RU5MbtZqhh0 IG+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=v3uvxlhpyVywOeCKfN58HL4kywyDPvCRWTa4uTmYA0Q=; fh=OU69p3CqxkGgoP7C0xyhoEUzoUHqWYGp3K8p8wRwEzw=; b=MwvT6+aKcyyq9U4/DML+UPOE35zg/syzJ9MEAvqvaltmk4PFJBHj54Rj1Jkfac8yAA 7sadAJb8Fikk9uDXchv497Gmpv1uJqnKiWwT01UZXwV/0mt5X5MJkMFs8/NIPSQBk4eH wR/zKRhZhgwF6Ow2ZrEfbOm6kq+2Y6igcK2MEVqLVJXYq/+cEXv2egifHZwmVbsQeQpg v44QZiMmsHS5JGpNVjXh0pFFMA6r4q/qqDwCfyoOgwXC7Cb0OHoQiQsIEEdOQwZT/oVe KMq4kiiiImoyKhPrmULdSbkE/cu5dgGncKB0Q43dbriXOz+X6/2eIbqftXTzBolne7lU D5ZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=cMBALboL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o2-20020aa7c502000000b0052a12558983si45454edq.303.2023.09.07.10.40.40; Thu, 07 Sep 2023 10:41:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=cMBALboL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233917AbjIGQBW (ORCPT + 99 others); Thu, 7 Sep 2023 12:01:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55880 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241844AbjIGP7U (ORCPT ); Thu, 7 Sep 2023 11:59:20 -0400 Received: from pandora.armlinux.org.uk (unknown [IPv6:2001:4d48:ad52:32c8:5054:ff:fe00:142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42F4A1FFC; Thu, 7 Sep 2023 08:48:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: 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=v3uvxlhpyVywOeCKfN58HL4kywyDPvCRWTa4uTmYA0Q=; b=cMBALboLcZQB/DNbVCwH0r0KjF FKs6pkrAoiU6XIpNGn6ZT3ykUCQ+Ce5ru2X0LJN/wi1zO4BFrFy21XM5xRndzViVJHmSjNc23KM3N 3tHi+R6HNKVPol+fFZa4SUU5JmE19W1F8uRQb4sBvD8S6qVOGhJkdmL6rX/MYhPu1mT0Zt525MV9j eQSsMWb9eZ/3yo6lAKWimBG3nTiy46dA0Vtoz8gVCUe0LTXe+6kaVdpkOeMBO8TclVjgR+WTH2Za/ 2mE5feR0C2jb11Owc26U78mi0p48ztIJuDaE635wnsqQdt0kRDvrdA7s0FDVSpDB14sWBKXvW2n9w vEI7gVwQ==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:57708) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1qeFUF-0003KZ-1Y; Thu, 07 Sep 2023 14:55:59 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1qeFUF-0005tY-7p; Thu, 07 Sep 2023 14:55:59 +0100 Date: Thu, 7 Sep 2023 14:55:59 +0100 From: "Russell King (Oracle)" To: Bagas Sanjaya Cc: Raul Piper , kernelnewbies@kernelnewbies.org, LKML , Linux ARM , Linux I2C , Linux Devicetree , Linus Walleij , Andi Shyti , Rob Herring , Krzysztof Kozlowski , Conor Dooley Subject: Re: Debugging i2c : i2cdetect cant detect a device on i2c line Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: Russell King (Oracle) X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED,RDNS_NONE, SPF_HELO_NONE,SPF_NONE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 07, 2023 at 08:36:32PM +0700, Bagas Sanjaya wrote: > [also Cc: devicetree and ARM folks] > > On Thu, Sep 07, 2023 at 08:21:44AM +0530, Raul Piper wrote: > > Hello , > > I am trying to detect an i2c device A on i2c1 line on one of the Arm > > Cortex A7 platform but not able to see any device on a given address ( > > 0x3d) . > > > > Is there any parameters of i2c which i can change like rise/fall time > > , timeout etc in a device tree or kernel source and re test it? > > I have tried changing the i2c speed from 100KHz to 400 KHz but no success. > > I have even tried removing the 1.5K pull ups on the i2c lines but no result. Honestly, from this description, I'm wondering if this posting is a joke. I2C is entirely _reliant_ on pull-ups. It's a wire-or bus, and the logic 1 state is created by no device pulling the signal low, thereby allowing the pull-up resistor to pull the line to the logic 1 state. The pull-up must be the correct strength for the devices on the bus. If it is too strong, then a driver may not be able to pull the signal sufficiently low for other devices to register it as a logic 0. Conversely, the pull-up must be strong enough so that the rise-time of the signal is sufficient to register as a logic 1. If it's a problem with the rise time, then increasing the clock rate will just make the situation worse. So, if other devices work on the bus, it could be that the Vil threshold of this device is not being achieved, whereas the other devices are happy. Therefore, I would suggest you study the data sheets of the device that isn't being detected. Lastly, if the undetectable device has a reset line, it's possible that the device isn't responding because it's being held in reset. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!