From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f43.google.com (mail-lf1-f43.google.com [209.85.167.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 164F136D9FA for ; Sun, 31 May 2026 10:42:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.43 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780224144; cv=none; b=RFEE2epm799G9i8MZ3Mz0atCkUGMmRTHtME6aZMIBFtsoL3+mzCZdDZ56E/1Ak5ecsVSy9ZvqF2fKx5uK1Zsg53pc/NoIBamvuFShWlMBlAO7n5+e5M3Vsn6Vfs43K1P4LosoCi8NMtIgvuqAjoRf8OOL9qe3bSiNqtusOeziQc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780224144; c=relaxed/simple; bh=IocCa73rf7kw/jZJ8Wjphwt1PovjtrER/bBR1M7xXNM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=KVN9bGlY2aSwXn3GdD6NN3TRK6uXuQB8uaN13yYFaccx1cKvKfoNIaTIQcUjgSwMsycKg8Z67oQuN2I8QDRwoJ6Y3I2cfI1Me0sl3TQ8PlFSZuwPsUIi2XviiOJ5z2bP8lZ/N3ku6lDBaz7SFUv4C0j0ZrAPUGioU0EUif87/CU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=pp/Qht4t; arc=none smtp.client-ip=209.85.167.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="pp/Qht4t" Received: by mail-lf1-f43.google.com with SMTP id 2adb3069b0e04-5aa68cd8dd3so313041e87.0 for ; Sun, 31 May 2026 03:42:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1780224141; x=1780828941; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=INehRWTHTBM1ilUwastePElIHNWnGH8n+SvXXUnd6iA=; b=pp/Qht4tG5f2xTyd9OCsMDBpGHCyX56saBZPfRPlezRY0y3djtDwTZgn3PbfNX+0rN uoyNpF8FQc1zC/W6iGDmYTGSZ4P2C5NyTAwW3VyHO3AUgqZWNUVINFD56mamC6rc9wo3 zLlo2Bf9Se0F2pVwjcIpGVAclNTe0kKzh1lYpAcDZM0WnLagy06kSAnAh9vjldueThy8 +xgmbn7gr31CTozhPptZGTrnpYY3unvj5U1EyEFrgWm7IqF0eg5eROxwSogdFjUWGGLf EDwiGG0p+t6C9HZTX2VW6v1sKxaE2+2gGB5BiWOjdoDXV4XvwsRdvaWb5m4auagLF8y6 zWWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780224141; x=1780828941; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=INehRWTHTBM1ilUwastePElIHNWnGH8n+SvXXUnd6iA=; b=mt/OUU0wmPIr2YF86HRB2Jb8Z1p/Yl5SBbQOtPFLetAKzgm1q2ci+aATkgqmBv/CFy GMNJqfISzpVkqD0pRdEh5+8/lo6vjoG+5bpIDrGm9gJVv/PtrgC/pcWT9aK/xeDa6kIy 26T0tHOPpi7KuweBoW3CA2in5/UqNrhNr6kzvjNlJ5vxI6VzW1D5RDtYgLvbtrY1N1Xd 3DkdnqJ+bZFPRItUsnzZ70y0WMRqKY9i7BHqn8p+BmN/dVbgH4yApZ4gY77+IJlH5HrY PN2Z6he99Tk5bVAnQgTE/wCkwaVMsGYN9fSgwKSEBpulBNW/TEuDWyc4231NoKp5GnoW IAsA== X-Forwarded-Encrypted: i=1; AFNElJ9m6pu+YGtt6mYwSDIfjuyeVlUsWAVGrn2UvFSpC/1K5h1zv7KxvwfkLdileFPfbTyFzaNta+PrYW1f3BY=@vger.kernel.org X-Gm-Message-State: AOJu0Yw1DNNHZLIWJeTxMQlYLhaR0Y6T9KwCCvZzfSbYr5D24hr4coGI 1FAdVJaDT19jeXz/4tI4PyzxGEugTQGNiqMdyoPu10qVTxdx+T+nek+N X-Gm-Gg: Acq92OGF3oNngT/jDctasRJOzhxpdEIvYn3OknAylf3TMCc0/bnc4D8QSvugepvXNIG ZvK+FB2xRyNEbpTR/BkXCqGhv//CGkX9qbv5fGAUjMCymXoKz3If29vPzxGCooUllgil17MmJNn JsqjeMqxB16yu4mrOovSAR9F7FJsRLHlY/kDu4EOHIgD0XG0Yw0/N0G6lM0mg8Jip8uhS5BHSXF jak+cieUsX495yqg29KDMTgsMtgVoXswkQhljMXrhlk9iPyO11P0c+aVy87k26bUfIiphNgBhCf zGjKqydzkUUnIeiFXyo0wDrWW5e/MOLBJFJxYFHYAmgYcoHO9N/IEUAUcW3sq+VzI/TPxXfy7Mp qtXAJ5ZFBf9P0kx37vYSxq3mJSywOI4EEz8k1HtCiG826ASrUWkJGAi0hjr/NnejT4h9ZPzt1JU bBE5w9fMcMOf7EAEQjfBGP9QZUVurmbO1wzcOqJ2a7EAXkPpHhJUVLJLgMpzBC1EM+jmwI4Os= X-Received: by 2002:a05:6512:398e:b0:5a7:46f2:9860 with SMTP id 2adb3069b0e04-5aa608ec07fmr1928751e87.20.1780224141104; Sun, 31 May 2026 03:42:21 -0700 (PDT) Received: from gmail.com (83-233-6-197.cust.bredband2.com. [83.233.6.197]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-5aa5b07214asm1480110e87.21.2026.05.31.03.42.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 May 2026 03:42:19 -0700 (PDT) Date: Sun, 31 May 2026 12:42:16 +0200 From: Marcus Folkesson To: Peter Rosin Cc: Wolfram Sang , Michael Hennerich , Bartosz Golaszewski , Andi Shyti , Andy Shevchenko , Bartosz Golaszewski , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v9 5/5] docs: i2c: i2c-topology: add section about bus speed Message-ID: References: <20260324-i2c-mux-v9-0-5292b0608243@gmail.com> <20260324-i2c-mux-v9-5-5292b0608243@gmail.com> <776cefab-fa6c-4092-8b95-236a3eaac729@lysator.liu.se> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <776cefab-fa6c-4092-8b95-236a3eaac729@lysator.liu.se> Hi Peter! On Sat, May 30, 2026 at 08:54:51AM +0200, Peter Rosin wrote: > Hi all, > > First off, sorry for being so incredibly slow in getting to this > series. No worries! [...] > > > +Consider the following example: :: > > > + > > > + .----------. 100kHz .--------. > > > + .--------. 400kHz | mux- |--------| dev D1 | > > > + | root |--+-----| locked | '--------' > > > + '--------' | | mux M1 |--. 400kHz .--------. > > > + | '----------' '--------| dev D2 | > > > + | .--------. '--------' > > > + '--| dev D3 | > > > + '--------' > > > + > > > +If the idle state of M1 is: > > > + > > > +- All channels disconnected: No problem, D1 and D2 are not affected by communication > > > + to D3. > > > +- Last selected channel: Problem if D1 was the last selected channel. High speed > > > + communication to D3 will be "leaked" to D1. > > > +- Predefined channel: Problem if the predefined channel D1. Set predefined channel > > > + to D2 as D2 may handle 400kHz. > > > > ... unlike here. We have MUX_IDLE_AS_IS and MUX_IDLE_DISCONNECT defined > > already. And I'd think we should only allow bus speed switching for > > MUX_IDLE_DISCONNECT to avoid out-of-spec scenarios. Opinions? > > It is probably not unwise to disallow MUX_IDLE_AS_IS in this context, > at least until someone actually needs it. Which does not seem all that > likely? I agree, I had this in my first iteration [1][2], but only as a warning though. Maybe I should reintroduce `idle_state` again and only allow MUX_IDLE_DISCONNECT? [1] https://lists.infradead.org/pipermail/linux-arm-kernel/2025-September/1064986.html [2] https://lists.infradead.org/pipermail/linux-arm-kernel/2025-September/1064987.html > > However, it seems like it should be fairly OK to allow a predefined > idle channel, as long as that channel is not lowering the bus speed > compared to the parent. But maybe supporting that can also wait for > an actual user? > > > > +Supported controllers > > > +----------------------- > > > + > > > +Not all I2C controllers support setting the bus speed dynamically. > > > +At the time of writing, the following controllers have support: > > > + > > > +============================ ============================================= > > > +i2c-davinci Supports dynamic bus speed > > > +============================ ============================================= > > > > This paragaph is easy to get outdated. We can document that only > > controller drivers with the callback function implemented will work. > > People then can find out if that applies for their driver... > > There are other such hard-to-maintain lists elsewhere in the text. > Not saying that this makes neither those nor this list a good idea, > but it is an explanation for adding one more. > > Cheers, > Peter Best regards, Marcus Folkesson