From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f49.google.com (mail-wm1-f49.google.com [209.85.128.49]) (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 9B0332D8383 for ; Tue, 13 Jan 2026 16:17:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.49 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768321069; cv=none; b=tU8aA3eqa7lpL9LaaGMXCgjhqHVMnxKobARsmb46cz9eJtH0rQa5tGCnfdi8sREk4+ktwPVhEODrfNUyq9DQlqdXRbIx6RJWJ/QPTP0c6A353el52mb1bx894FWIICEKucAoRMcdiarARod7Afvcj4a+IUDA64488WMTnuFCYCQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768321069; c=relaxed/simple; bh=yMU7RpmbGUQmgjsLmbNXZu5aW050fDW5MvKwtfgFqbg=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=fPjvyJbpzqIUz36cKfkU+IZf4A86agajFZQbSd5KKyb9KPrdKP9UjFNabzYJCboNme2ZbhuxqK8ksTeJyAvsuoYIV0YEjNSnT5T//LygPETA26akyN5JU0GFl/ANQcBA+KISYAMgx82YSA4viExM/bPcAXLFPfwAliS7FB1unBQ= 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=mOmuMFYK; arc=none smtp.client-ip=209.85.128.49 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="mOmuMFYK" Received: by mail-wm1-f49.google.com with SMTP id 5b1f17b1804b1-47eddddcdcfso3232805e9.1 for ; Tue, 13 Jan 2026 08:17:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768321065; x=1768925865; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=W5cQ5QbTEmkxlUwQtqiRbc+zlLlHGcmwQl/sOQIOejY=; b=mOmuMFYK3cMMLXUbn18dKxh4ntuwCPofy0p/wza2YLcAvXEncPZaUzVDnszC5vUuCr EtwKO47htMVN5EdpERh46uz6wEXHZHEDSuW67mUPTdzFF1wlMWoYzbnn9MWrN/3JieGc txD5TKpF7U8PPN2WW9o4JOawzYN8WC1tReCsBW65eNGXEDkZzg8np8NuAcCoONqX8oVO 187MKh1LzZe9pdyfZyV139pIKhtcIEC2NPRbrMj8XEF0qcdIfKHqJJutVAWAeoKwYfjA tSfQ09mBre4EIs6lT8YK703RZR+TEpxmdfBvemDwnhriY70Mzl4L6YOSVIfvNEdvN8PX lWYA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768321065; x=1768925865; h=in-reply-to:content-transfer-encoding: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=W5cQ5QbTEmkxlUwQtqiRbc+zlLlHGcmwQl/sOQIOejY=; b=o5pi8Kcey3Gu51ZVSCGF9PPBhhOIumXvPheWLe8qYS3Xkz7Aw9v7mavRsQM3Eh7Fsl 6YOQsNo8wpdvfaODmNppj2j6cFo1/l2v9dORiRsWb0dbh7Q1yxGWL0jQnzxeaY9Ke+ha NRgHZC2Exjfq7oqPFwphTN6qcTOHHMhJsxQhfwI0vdOU/kzuRnWNO1BOo6bEFkYCip4J HiWArkZvc0uCGG1Hsw0EOK7GuNa5WaQSO9td0lAtU+lPr30wdVpSbo/UkdP45fbnX0Gs yyoEH78Sv/9fttEllAcwCWMbeNwT9BLgBQlejAC9WWTR/14x2ldB/USOzNdD5r8sgkgx HgOQ== X-Forwarded-Encrypted: i=1; AJvYcCXnRJTH/rEo0Z/vspucfaDKCLomAX8yqA/QNPVipfx7pDwbFZKh3FCKHAfyqPzZz96JF23nARbOeXyADhQ=@vger.kernel.org X-Gm-Message-State: AOJu0YwtIBP34MpYqaYQIbpYlnjZHQ6QVe9xxInRkv7vV/F73M4461In cvRApnrEjxsa3DXWNtZRlfCSk1oTI5NUtbWyIWwE2Ed450FTZaJ4Jg5s X-Gm-Gg: AY/fxX48CMSlkCVNa3YhxPRzcwPBR/5uPnA7e8720+RxeNl7ByPsEQnQXDm/e9o6WtI g/GxCev47r3TA5LO3VaWPO3zSuqEYzLlt/Vef6lOPGpjv07oGg4jbV1Fpxn1Z5MrwjRRHhohU7T XvzOOL7SjerWc6R31Tlgp+ZIf46ItR77JO64gQiZYU0ehDO1+tjFkQM36c4de1SYW3YeKzU27t4 vTC7fMNCq3+f3lxD02vUbOP1jQ6DRb0mqzROskQZkqj2b9a7/4KvP7suCElaOD+KdrlKzUoZQJg Tmek8l/XmyH4Psegygb3Mtmc+NGZH3g0+sG2igLr50amQVgk2aW2+HNn/thre8dp3YNc30U13ht sLtNuXFeqF0YU6EEAgnlYeIyO+h6drtKZ1HHz9WwDUpE4ZkHimbV5TFTHfE5k7wJMSo8usxzzbK qBU3NrRrlOskYcsFQNUJRH/7CH2Oz2OJutJJLi+y25OC/kyaEZUNm+L2ABQErQahGQ X-Google-Smtp-Source: AGHT+IEAzrK93inVXSrX8Kw6zVEeuZ0+E8dHH/rXiqvCESoJ7JG5E/eH8JB47SON6HhjECNrEiGHSQ== X-Received: by 2002:a05:600c:34cb:b0:47a:9560:5944 with SMTP id 5b1f17b1804b1-47d8f287ae3mr154134765e9.34.1768321064788; Tue, 13 Jan 2026 08:17:44 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47edc05b267sm36951725e9.15.2026.01.13.08.17.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:17:43 -0800 (PST) Date: Tue, 13 Jan 2026 16:17:43 +0000 From: Stafford Horne To: Bartosz Golaszewski Cc: Linus Walleij , Geert Uytterhoeven , LKML , Linux OpenRISC , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-gpio@vger.kernel.org, devicetree@vger.kernel.org Subject: Re: [PATCH v2 1/5] dt-bindings: Add compatible string opencores,gpio to gpio-mmio Message-ID: References: <20251217080843.70621-1-shorne@gmail.com> <20251217080843.70621-2-shorne@gmail.com> 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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Mon, Jan 12, 2026 at 10:25:03AM +0100, Bartosz Golaszewski wrote: > On Fri, Jan 9, 2026 at 1:51 PM Stafford Horne wrote: > > > > On Fri, Jan 09, 2026 at 11:07:17AM +0100, Linus Walleij wrote: > > > On Thu, Jan 8, 2026 at 9:41 AM Geert Uytterhoeven wrote: > > > > > > > > > What is the rationale behind using brcm,bcm6345-gpio? > > > > > > Given brcm,bcm6345-gpio has 32-bit registers, while opencores,gpio > > > > > > has 8-bit registers, I doubt the latter is compatible with the former... > > > > > > Yeah this needs to be fixed/reverted pronto :/ > > > > > > > > I switch the size from 32-bit to 8-bit using the reg = <* 0x1>, <* 0x1> setting. > > > > > Also the reg addresses of "dat" and "dirout" are different for the real > > > > > brcm,bcm6345-gpio. > > > > > > > > > > brcm,bcm6345-gpio. Example: > > > > > > > > > > /* GPIOs 192 .. 223 */ > > > > > gpio6: gpio@518 { > > > > > compatible = "brcm,bcm6345-gpio"; > > > > > reg = <0x518 0x04>, <0x538 0x04>; > > > > > reg-names = "dirout", "dat"; > > > > > gpio-controller; > > > > > #gpio-cells = <2>; > > > > > }; > > > > > > > > > > vs opencores,gpio Example: > > > > > > > > > > gpio0: gpio@91000000 { > > > > > compatible = "opencores,gpio", "brcm,bcm6345-gpio"; > > > > > reg = <0x91000000 0x1>, <0x91000001 0x1>; > > > > > reg-names = "dat", "dirout"; > > > > > gpio-controller; > > > > > #gpio-cells = <2>; > > > > > }; > > > > > > > > Exactly, the register space and register widths are different > > > > > > ...as proved here. > > > > > > Stafford can you send a fixup or revert patch? > > > (Only need to revert if you can't make a fix quick enough, which I > > > think you can.) > > > > Sure, I'll send a fixup to the devicetree binding and a update to the driver to > > just support opencores,gpio. > > > > I assume, the v3 you sent is *not* it and you will send a v4 with > issues pointed out by Krzysztof fixes? Yes, I have just sent out the v4. > > Hopefully, that can be picked up in time by Bartosz who has this one staged in > > gpio/for-next. > > > > I'm ready to pick it up as soon as Krzysztof Acks it. OK. > > I'll send the 2 patches as part of my series for OpenRISC multicore fixups as > > the devicetree's I have added have a soft dependency the patches. After/if the > > patches are pulled to the gpio branch I can drop them from my queue and I'll > > just have to make sure Linux merged the GPIO changes binding updates before the > > OpenRISC updates during the merge window. Let me know if there are any issues. > > > > Sounds good. Thank you. -Stafford > > > > > The opencores,gpio setup does work. > > > > > > > > > > Now that I think about it, would it have been better to just add opencores,gpio > > > > > to gpio-mmio.c compatible list? > > > > > > > > I think that would be better. > > > > > > Yes this is better. > > > > > > I should have seen this, I guess I was sloppy :( > > > > I should have also thought more, but I don't do this often enough to remember > > all of the rules. Sorry for the head ache. > > > > -Stafford