Module Name: src Committed By: thorpej Date: Sun May 31 23:52:19 UTC 2020
Modified Files: src/sys/arch/arm/broadcom: bcm2835_bsc_fdt.c bcm2835_emmc.c bcm2835_sdhost.c Log Message: Remove superfluous checking for a "disable" property in the device_t properties dictionary. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c cvs rdiff -u -r1.36 -r1.37 src/sys/arch/arm/broadcom/bcm2835_emmc.c cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/broadcom/bcm2835_sdhost.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c diff -u src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c:1.1 src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c:1.2 --- src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c:1.1 Tue Mar 31 12:23:17 2020 +++ src/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c Sun May 31 23:52:19 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: bcm2835_bsc_fdt.c,v 1.1 2020/03/31 12:23:17 jmcneill Exp $ */ +/* $NetBSD: bcm2835_bsc_fdt.c,v 1.2 2020/05/31 23:52:19 thorpej Exp $ */ /* * Copyright (c) 2019 Jason R. Thorpe @@ -28,7 +28,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: bcm2835_bsc_fdt.c,v 1.1 2020/03/31 12:23:17 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: bcm2835_bsc_fdt.c,v 1.2 2020/05/31 23:52:19 thorpej Exp $"); #include <sys/param.h> #include <sys/bus.h> @@ -67,8 +67,6 @@ bsciic_fdt_attach(device_t parent, devic struct bsciic_softc * const sc = device_private(self); struct fdt_attach_args * const faa = aux; const int phandle = faa->faa_phandle; - prop_dictionary_t prop = device_properties(self); - bool disable = false; bus_addr_t addr; bus_size_t size; @@ -82,13 +80,6 @@ bsciic_fdt_attach(device_t parent, devic return; } - prop_dictionary_get_bool(prop, "disable", &disable); - if (disable) { - aprint_naive(": disabled\n"); - aprint_normal(": disabled\n"); - return; - } - /* Enable clock */ sc->sc_clk = fdtbus_clock_get_index(phandle, 0); if (sc->sc_clk == NULL) { Index: src/sys/arch/arm/broadcom/bcm2835_emmc.c diff -u src/sys/arch/arm/broadcom/bcm2835_emmc.c:1.36 src/sys/arch/arm/broadcom/bcm2835_emmc.c:1.37 --- src/sys/arch/arm/broadcom/bcm2835_emmc.c:1.36 Thu Feb 20 01:44:06 2020 +++ src/sys/arch/arm/broadcom/bcm2835_emmc.c Sun May 31 23:52:19 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: bcm2835_emmc.c,v 1.36 2020/02/20 01:44:06 jmcneill Exp $ */ +/* $NetBSD: bcm2835_emmc.c,v 1.37 2020/05/31 23:52:19 thorpej Exp $ */ /*- * Copyright (c) 2012 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: bcm2835_emmc.c,v 1.36 2020/02/20 01:44:06 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: bcm2835_emmc.c,v 1.37 2020/05/31 23:52:19 thorpej Exp $"); #include "bcmdmac.h" @@ -117,9 +117,7 @@ bcmemmc_attach(device_t parent, device_t { struct bcmemmc_softc *sc = device_private(self); struct fdt_attach_args * const faa = aux; - prop_dictionary_t dict = device_properties(self); const int phandle = faa->faa_phandle; - bool disable = false; enum bcmemmc_type type; int error; @@ -138,13 +136,6 @@ bcmemmc_attach(device_t parent, device_t sc->sc.sc_clkbase = 50000; /* Default to 50MHz */ sc->sc_iot = faa->faa_bst; - prop_dictionary_get_bool(dict, "disable", &disable); - if (disable) { - aprint_naive(": disabled\n"); - aprint_normal(": disabled\n"); - return; - } - bus_addr_t addr; bus_size_t size; Index: src/sys/arch/arm/broadcom/bcm2835_sdhost.c diff -u src/sys/arch/arm/broadcom/bcm2835_sdhost.c:1.4 src/sys/arch/arm/broadcom/bcm2835_sdhost.c:1.5 --- src/sys/arch/arm/broadcom/bcm2835_sdhost.c:1.4 Sun Dec 10 21:38:26 2017 +++ src/sys/arch/arm/broadcom/bcm2835_sdhost.c Sun May 31 23:52:19 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: bcm2835_sdhost.c,v 1.4 2017/12/10 21:38:26 skrll Exp $ */ +/* $NetBSD: bcm2835_sdhost.c,v 1.5 2020/05/31 23:52:19 thorpej Exp $ */ /*- * Copyright (c) 2017 Jared McNeill <jmcne...@invisible.ca> @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: bcm2835_sdhost.c,v 1.4 2017/12/10 21:38:26 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: bcm2835_sdhost.c,v 1.5 2020/05/31 23:52:19 thorpej Exp $"); #include "bcmdmac.h" @@ -191,8 +191,6 @@ sdhost_attach(device_t parent, device_t { struct sdhost_softc * const sc = device_private(self); struct fdt_attach_args * const faa = aux; - prop_dictionary_t dict = device_properties(self); - bool disable = false; sc->sc_dev = self; sc->sc_bst = faa->faa_bst; @@ -220,12 +218,6 @@ sdhost_attach(device_t parent, device_t aprint_naive("\n"); aprint_normal(": SD HOST controller\n"); - prop_dictionary_get_bool(dict, "disable", &disable); - if (disable) { - aprint_naive(": disabled\n"); - aprint_normal(": disabled\n"); - return; - } /* Enable clocks */ struct clk *clk; for (int i = 0; (clk = fdtbus_clock_get_index(phandle, i)); i++) {