From owner-freebsd-arm@freebsd.org Fri Jan 19 20:30:40 2018 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 07CF5EC638D for ; Fri, 19 Jan 2018 20:30:40 +0000 (UTC) (envelope-from byond.lenox@gmail.com) Received: from mail-it0-f41.google.com (mail-it0-f41.google.com [209.85.214.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C80D273363 for ; Fri, 19 Jan 2018 20:30:39 +0000 (UTC) (envelope-from byond.lenox@gmail.com) Received: by mail-it0-f41.google.com with SMTP id u62so3523772ita.2 for ; Fri, 19 Jan 2018 12:30:39 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=P1S/6y4XBgBNCjabexQarX8DjDit5J1g+7PvttEl/ag=; b=DlkviNaXJt5+B0mpkaZX9tQKZWEk8gzuqNdkuwqF6cSVgrmZuvL19kJxes/izPFNkC p+WWTbXsJtsqzEPslMKnJrueE8w+T9E4pRLQzY4MO8WpZ8qk2ewLyaucmJyCxKXxf0iV YQd0Ieh/UKoj7VkEg4U+lJxxjp9ZkLGo6Pf4bBnFohosGXoVaR2PiAacS3fYPvLa/fQd mRkMTF95+MTBOQyy9LboRRKOtZijf2YSkZ0bBeEwv2WLFgHchGqWsWw2K+VNaUw8bC4n 5Ru0zDWd9ASrTzDsbLGLKF3pT9S0WzyTI7IOjG+g/RAyrD9jp2q67ot6I0TqN3RMlfui ptqg== X-Gm-Message-State: AKwxytdJMjw5VFxo1qrxXZHX/f/3cyJ+VK/yu9Fn7v+Mn50MmSIoDDzh GjPABkj8V2teFUxr2LEz4mQ7cCxm X-Google-Smtp-Source: AH8x225/3sGz7Fx1+cizeWGlIGVlgrUNyKiPY67mMU/MMHfr25kSyvQqfD4CSOysYliWyauOcljOnQ== X-Received: by 10.36.58.11 with SMTP id m11mr165469itm.89.1516393832668; Fri, 19 Jan 2018 12:30:32 -0800 (PST) Received: from mail-it0-f42.google.com (mail-it0-f42.google.com. [209.85.214.42]) by smtp.gmail.com with ESMTPSA id y64sm5898098ioy.25.2018.01.19.12.30.32 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 19 Jan 2018 12:30:32 -0800 (PST) Received: by mail-it0-f42.google.com with SMTP id c16so3517645itc.5 for ; Fri, 19 Jan 2018 12:30:32 -0800 (PST) X-Received: by 10.36.36.66 with SMTP id f63mr187256ita.41.1516393831793; Fri, 19 Jan 2018 12:30:31 -0800 (PST) MIME-Version: 1.0 Received: by 10.107.157.12 with HTTP; Fri, 19 Jan 2018 12:30:11 -0800 (PST) In-Reply-To: <20180119211953.5140bb57@zeta.dino.sk> References: <20180119211953.5140bb57@zeta.dino.sk> From: Kyle Evans Date: Fri, 19 Jan 2018 14:30:11 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Orange Pi R1 ethernet #2 + SDIO question To: Milan Obuch Cc: "freebsd-arm@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jan 2018 20:30:40 -0000 On Fri, Jan 19, 2018 at 2:19 PM, Milan Obuch wrote: > Hi, > > today I looked over some docs about Orange Pi R1's second ethernet > interface. Actually it is basically the same board as Orange Pi Zero, > just onboard USB connector is replaced with some Realtek USB ethernet > chip. With our current kernel and Orange Pi Zero DTB there is nothing > in usbconfig output. > > Most probably we are missing some initialization step. After finding > mention of GPIO pin 20 in some Linux DTS, I decided simply try > > # gpioctl -f /dev/gpioc0 20 1 > > and voila, it works: > > ugen2.2: at usbus2 > ure0 on uhub1 > ure0: on usbus2 > random: harvesting attach, 8 bytes (4 bits) from ure0 > miibus1: on ure0 > rlphy0: PHY 0 on miibus1 > rlphy0: OUI 0x00e04c, model 0x0008, rev. 2 > rlphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto > random: harvesting attach, 8 bytes (4 bits) from rlphy0 > random: harvesting attach, 8 bytes (4 bits) from miibus1 > ue0: on ure0 > ue0: bpf attached > ue0: Ethernet address: c0:74:2b:ff:e5:ff > ue0: link state changed to DOWN > > After > > # dhclient ue0 > > I was able to use this USB ethernet interface. > > Maybe this activation could be inserted in DTS, but for now I consider > this ethernet usable (I tried some ping, ssh and some such over it with > success). I can't comment on SDIO, but this stuff should ride in on 4.16 DTS in a couple months and just work; see [1]. [1] https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux.git/tree/arch/arm/boot/dts/sun8i-h2-plus-orangepi-r1.dts?h=sunxi/for-next