1422d05daSIan Lepore.\"- 2422d05daSIan Lepore.\" SPDX-License-Identifier: BSD-2-Clause 3422d05daSIan Lepore.\" 4422d05daSIan Lepore.\" Copyright (c) 2019 Ian Lepore <ian@freebsd.org> 5422d05daSIan Lepore.\" 6422d05daSIan Lepore.\" Redistribution and use in source and binary forms, with or without 7422d05daSIan Lepore.\" modification, are permitted provided that the following conditions 8422d05daSIan Lepore.\" are met: 9422d05daSIan Lepore.\" 1. Redistributions of source code must retain the above copyright 10422d05daSIan Lepore.\" notice, this list of conditions and the following disclaimer. 11422d05daSIan Lepore.\" 2. Redistributions in binary form must reproduce the above copyright 12422d05daSIan Lepore.\" notice, this list of conditions and the following disclaimer in the 13422d05daSIan Lepore.\" documentation and/or other materials provided with the distribution. 14422d05daSIan Lepore.\" 15422d05daSIan Lepore.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 16422d05daSIan Lepore.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 17422d05daSIan Lepore.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 18422d05daSIan Lepore.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 19422d05daSIan Lepore.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20422d05daSIan Lepore.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21422d05daSIan Lepore.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22422d05daSIan Lepore.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23422d05daSIan Lepore.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24422d05daSIan Lepore.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25422d05daSIan Lepore.\" SUCH DAMAGE. 26422d05daSIan Lepore.\" 27422d05daSIan Lepore.\" $FreeBSD$ 28422d05daSIan Lepore.\" 29422d05daSIan Lepore.Dd January 1, 2020 30422d05daSIan Lepore.Dt IIC_GPIOMUX 4 31422d05daSIan Lepore.Os 32422d05daSIan Lepore.Sh NAME 33422d05daSIan Lepore.Nm iic_gpiomux 34422d05daSIan Lepore.Nd driver for I2C mux hardware controlled via GPIO 35422d05daSIan Lepore.Sh SYNOPSIS 36422d05daSIan LeporeTo compile this driver into the kernel, 37422d05daSIan Leporeplace the following line in your 38422d05daSIan Leporekernel configuration file: 39422d05daSIan Lepore.Bd -ragged -offset indent 40422d05daSIan Lepore.Cd "device iic_gpiomux" 41422d05daSIan Lepore.Ed 42422d05daSIan Lepore.Pp 43422d05daSIan LeporeAlternatively, to load the driver as a 44422d05daSIan Leporemodule at boot time, place the following line in 45422d05daSIan Lepore.Xr loader.conf 5 : 46422d05daSIan Lepore.Bd -literal -offset indent 47422d05daSIan Leporeiic_gpiomux_load="YES" 48422d05daSIan Lepore.Ed 49422d05daSIan Lepore.Sh DESCRIPTION 50422d05daSIan LeporeThe 51422d05daSIan Lepore.Nm 52422d05daSIan Leporedriver supports any type of I2C bus multiplexer (mux) hardware that 53422d05daSIan Leporeis controlled by manipulating the state of one or more GPIO pins. 54422d05daSIan LeporeIt automatically connects an upstream I2C bus to one of the downstream 55422d05daSIan Leporebuses as needed when slave devices on the downstream buses initiate I/O. 56422d05daSIan LeporeMore information on the automatic switching behavior is available in 57422d05daSIan Lepore.Xr iicmux 4 . 58422d05daSIan Lepore.Sh FDT CONFIGURATION 59422d05daSIan LeporeOn an 60422d05daSIan Lepore.Xr fdt 4 61422d05daSIan Leporebased system, an 62422d05daSIan Lepore.Nm 63422d05daSIan Leporedevice node may be defined as a child node of any arbitrary bus 64422d05daSIan Leporein the FDT data. 65422d05daSIan LeporeThe 66422d05daSIan Lepore.Va i2c-parent 67422d05daSIan Leporeproperty indicates the connection to the upstream I2C bus. 68422d05daSIan LeporeThe children of the 69422d05daSIan Lepore.Nm 70422d05daSIan Leporenode are additional i2c buses, which will have their own i2c slave 71422d05daSIan Leporedevices described in their child nodes. 72422d05daSIan Lepore.Pp 73422d05daSIan LeporeThe 74422d05daSIan Lepore.Nm 75422d05daSIan Leporedriver conforms to the standard 76422d05daSIan Lepore.Bk -words 77422d05daSIan Lepore.Li i2c/i2c-mux-gpio.txt 78422d05daSIan Lepore.Ek 79422d05daSIan Leporebindings document. 80422d05daSIan Lepore.Sh SEE ALSO 81422d05daSIan Lepore.Xr iicbus 4 , 82*16ee5cd1SChristian Brueffer.Xr iicmux 4 83422d05daSIan Lepore.Sh HISTORY 84422d05daSIan LeporeThe 85422d05daSIan Lepore.Nm 86422d05daSIan Leporedriver first appeared in 87422d05daSIan Lepore.Fx 13.0 . 88