From owner-freebsd-arm@freebsd.org Thu Nov 28 14:09:46 2019 Return-Path: Delivered-To: freebsd-arm@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DD7BD1AAC7A for ; Thu, 28 Nov 2019 14:09:46 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 47NzzZ5PC6z4cPc for ; Thu, 28 Nov 2019 14:09:46 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from mail-qk1-f176.google.com (mail-qk1-f176.google.com [209.85.222.176]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) (Authenticated sender: kevans) by smtp.freebsd.org (Postfix) with ESMTPSA id 90A82969A for ; Thu, 28 Nov 2019 14:09:46 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: by mail-qk1-f176.google.com with SMTP id d124so7634417qke.6 for ; Thu, 28 Nov 2019 06:09:46 -0800 (PST) X-Gm-Message-State: APjAAAWKntwCAMimF0rrrktIryi3iP9hyCF6eStEdwOiHldr3bRgdsZ/ alMU64J6xCJMemN/AZx4eiWoQjh+RTiwnHd+pKQ= X-Google-Smtp-Source: APXvYqxQj1IEAfRgtUXMvDyowLM+XLhqAzgJBMhcc1eVQBbjQPztwN+TARYfqai8ElgPXzUwBzKVPSADtx1rZ9Zqb7A= X-Received: by 2002:ae9:eb53:: with SMTP id b80mr5749014qkg.430.1574950185839; Thu, 28 Nov 2019 06:09:45 -0800 (PST) MIME-Version: 1.0 References: <20191128152901.39dbeb4d@thinkpad> <20191128144934.34289c13@zeta.dino.sk> <20191128155257.66288428@thinkpad> <20191128145915.0d2bd63f@zeta.dino.sk> In-Reply-To: <20191128145915.0d2bd63f@zeta.dino.sk> From: Kyle Evans Date: Thu, 28 Nov 2019 08:09:34 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: gpioiic FDT overlays for sun8i-h3 To: Milan Obuch Cc: Nick Kostirya , "freebsd-arm@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Nov 2019 14:09:46 -0000 On Thu, Nov 28, 2019 at 7:59 AM Milan Obuch wrote: > > On Thu, 28 Nov 2019 15:52:57 +0200 > Nick Kostirya wrote: > > > On Thu, 28 Nov 2019 14:49:34 +0100 > > Milan Obuch wrote: > > > > > On Thu, 28 Nov 2019 15:29:01 +0200 > > > Nick Kostirya via freebsd-arm wrote: > > > > > > > Hello. > > > > I want use gpioiic on Nanopi NEO with PA0 and PA2 pins. > > > > Nanopi NEO will be master. > > > > Help me, please, to write overlay. > > > > I write: > > > > > > > > /dts-v1/; > > > > /plugin/; > > > > > > > > / { > > > > compatible = "allwinner,sun8i-h3"; > > > > }; > > > > > > > > &{/soc/} { > > > > gpio: gpio { > > > > gpio-controller; > > > > > > > > gpioiic0 { > > > > compatible = "gpioiic"; > > > > gpios = <&gpio 00 1 0 &gpio 02 1 0>; /* Attach to GPIO > > > > pins 00 and 02. Set them initially as inputs. */ scl = <0>; /* > > > > GPIO pin 00 (PA0) */ sda = <1>; /* GPIO pin 02 (PA2) */ > > > > > > > > }; > > > > }; > > > > }; > > > > > > > > But it is not worked. > > > > Tell me, please, where I was wrong. > > > > > > > > > > Quick question - which OS version? According to my experience, DTB > > > overlays do not work in FreeBSD 12, but everything is OK with them > > > in FreeBSD 13. > > > > FreeBSD 12.1 arm > > That's it - most probably it works if you try the same with newer > FreeBSD 13-CURRENT. At least for me overlays did not work with usual > FreeBSD 12-STABLE, after switching to FreeBSD 13-CURRENT it's OK. Try > to create secondary SD card with FreeBSD 13-CURRENT. I do not know the > details why. Somebody(tm) with working knowledge of overlay's internals > need to look it up. > What? This would have been good to know. =( How exactly are they failing? We haven't changed anything that would have regressed overlays in 12, unless you're basing your overlays on the wrong base fdt. Thanks, Kyle Evans