Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/i2c trailing whitespace



details:   https://anonhg.NetBSD.org/src/rev/4c5b7ea2f2bd
branches:  trunk
changeset: 958919:4c5b7ea2f2bd
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Sun Jan 24 19:35:21 2021 +0000

description:
trailing whitespace

diffstat:

 sys/dev/i2c/i2cmux.c    |  38 +++++++++++++++++++-------------------
 sys/dev/i2c/i2cmuxvar.h |  10 +++++-----
 sys/dev/i2c/pcai2cmux.c |  10 +++++++---
 3 files changed, 31 insertions(+), 27 deletions(-)

diffs (171 lines):

diff -r 10c03e0bad19 -r 4c5b7ea2f2bd sys/dev/i2c/i2cmux.c
--- a/sys/dev/i2c/i2cmux.c      Sun Jan 24 19:30:18 2021 +0000
+++ b/sys/dev/i2c/i2cmux.c      Sun Jan 24 19:35:21 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i2cmux.c,v 1.1 2020/12/28 20:29:57 thorpej Exp $       */
+/*     $NetBSD: i2cmux.c,v 1.2 2021/01/24 19:35:21 jmcneill Exp $      */
 
 /*-
  * Copyright (c) 2020 The NetBSD Foundation, Inc.
@@ -15,7 +15,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- *      
+ *
  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
@@ -26,44 +26,44 @@
  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE. 
- */     
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i2cmux.c,v 1.1 2020/12/28 20:29:57 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i2cmux.c,v 1.2 2021/01/24 19:35:21 jmcneill Exp $");
 
 #include <sys/types.h>
 #include <sys/device.h>
 #include <sys/kernel.h>
-#include <sys/kmem.h> 
+#include <sys/kmem.h>
 
 #include <dev/fdt/fdtvar.h>
 #include <dev/i2c/i2cvar.h>
 #include <dev/i2c/i2cmuxvar.h>
 
-/* 
- * i2c mux 
- * 
+/*
+ * i2c mux
+ *
  * This works by interposing a set of virtual controllers behind the real
  * i2c controller.  We provide our own acquire and release functions that
  * perform the following tasks:
- *    
+ *
  *     acquire -> acquire parent controller, program mux
- * 
+ *
  *     release -> idle mux, release parent controller
- * 
+ *
  * All of the actual I/O operations are transparently passed through.
- * 
- * N.B. the locking order; the generic I2C layer has already acquired  
+ *
+ * N.B. the locking order; the generic I2C layer has already acquired
  * our virtual controller's mutex before calling our acquire function,
- * and we will then acquire the real controller's mutex when we acquire 
+ * and we will then acquire the real controller's mutex when we acquire
  * the bus, so the order is:
- * 
+ *
  *     mux virtual controller -> parent controller
  *
  * These are common routines used by various i2c mux controller
  * implementations (gpio, pin mux, i2c device, etc.).
- */     
+ */
 
 /*****************************************************************************/
 
@@ -141,7 +141,7 @@
 /* XXX iicbus_print() should be able to do this. */
 static int
 iicmux_print(void * const aux, const char * const pnp)
-{         
+{
        i2c_tag_t const tag = aux;
        struct iicmux_bus * const bus = tag->ic_cookie;
        int rv;
@@ -152,7 +152,7 @@
        return rv;
 }
 
-static void 
+static void
 iicmux_attach_bus(struct iicmux_softc * const sc,
     int const phandle, int const busidx)
 {
diff -r 10c03e0bad19 -r 4c5b7ea2f2bd sys/dev/i2c/i2cmuxvar.h
--- a/sys/dev/i2c/i2cmuxvar.h   Sun Jan 24 19:30:18 2021 +0000
+++ b/sys/dev/i2c/i2cmuxvar.h   Sun Jan 24 19:35:21 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i2cmuxvar.h,v 1.1 2020/12/28 20:29:57 thorpej Exp $    */
+/*     $NetBSD: i2cmuxvar.h,v 1.2 2021/01/24 19:35:45 jmcneill Exp $   */
 
 /*-
  * Copyright (c) 2020 The NetBSD Foundation, Inc.
@@ -15,7 +15,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- *      
+ *
  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
@@ -26,15 +26,15 @@
  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE. 
- */     
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef _DEV_I2C_I2CMUXVAR_H_
 #define        _DEV_I2C_I2CMUXVAR_H_
 
 #include <dev/i2c/i2cvar.h>
 
-struct iicmux_softc;  
+struct iicmux_softc;
 struct iicmux_bus;
 
 struct iicmux_config {
diff -r 10c03e0bad19 -r 4c5b7ea2f2bd sys/dev/i2c/pcai2cmux.c
--- a/sys/dev/i2c/pcai2cmux.c   Sun Jan 24 19:30:18 2021 +0000
+++ b/sys/dev/i2c/pcai2cmux.c   Sun Jan 24 19:35:21 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pcai2cmux.c,v 1.3 2021/01/18 15:28:21 thorpej Exp $    */
+/*     $NetBSD: pcai2cmux.c,v 1.4 2021/01/24 19:37:45 jmcneill Exp $   */
 
 /*-
  * Copyright (c) 2020 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pcai2cmux.c,v 1.3 2021/01/18 15:28:21 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pcai2cmux.c,v 1.4 2021/01/24 19:37:45 jmcneill Exp $");
 
 /*
  * Driver for NXP PCA954x / PCA984x I2C switches and multiplexers.
@@ -126,6 +126,10 @@
        { .compat = "nxp,pca9547",
          .data = &mux8_type },
 
+       /* PCA9547 - 8 channel i2c mux (NXP Layerscape ACPI) */
+       { .compat = "NXP0002",
+         .data = &mux8_type },
+
        /* PCA9548 - 8 channel i2c switch */
        { .compat = "nxp,pca9548",
          .data = &switch8_type },
@@ -291,7 +295,7 @@
        if (iic_use_direct_match(ia, cf, compat_data, &match_result)) {
                return match_result;
        }
-       
+
        /* This device is direct-config only. */
 
        return 0;



Home | Main Index | Thread Index | Old Index