From owner-svn-src-all@freebsd.org Sun Apr 17 02:05:46 2016 Return-Path: Delivered-To: svn-src-all@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 B4E57B100DF; Sun, 17 Apr 2016 02:05:46 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 851B51A30; Sun, 17 Apr 2016 02:05:46 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3H25j1U021449; Sun, 17 Apr 2016 02:05:45 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3H25jrw021447; Sun, 17 Apr 2016 02:05:45 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201604170205.u3H25jrw021447@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Sun, 17 Apr 2016 02:05:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r298136 - head/sys/dev/flash X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Apr 2016 02:05:46 -0000 Author: adrian Date: Sun Apr 17 02:05:45 2016 New Revision: 298136 URL: https://svnweb.freebsd.org/changeset/base/298136 Log: Only compile the FDT bits when we are using FDT. Modified: head/sys/dev/flash/at45d.c head/sys/dev/flash/mx25l.c Modified: head/sys/dev/flash/at45d.c ============================================================================== --- head/sys/dev/flash/at45d.c Sun Apr 17 01:38:37 2016 (r298135) +++ head/sys/dev/flash/at45d.c Sun Apr 17 02:05:45 2016 (r298136) @@ -121,7 +121,7 @@ static int at45d_get_status(device_t dev, uint8_t *status) { uint8_t rxBuf[8], txBuf[8]; - struct spi_command cmd; + struct spi_command cmd = SPI_COMMAND_INITIALIZER; int err; memset(&cmd, 0, sizeof(cmd)); @@ -141,7 +141,7 @@ static int at45d_get_mfg_info(device_t dev, uint8_t *resp) { uint8_t rxBuf[8], txBuf[8]; - struct spi_command cmd; + struct spi_command cmd = SPI_COMMAND_INITIALIZER; int err; memset(&cmd, 0, sizeof(cmd)); @@ -303,7 +303,7 @@ at45d_task(void *arg) uint8_t rxBuf[8], txBuf[8]; struct at45d_softc *sc; struct bio *bp; - struct spi_command cmd; + struct spi_command cmd = SPI_COMMAND_INITIALIZER; device_t dev, pdev; caddr_t buf; u_long len, resid; Modified: head/sys/dev/flash/mx25l.c ============================================================================== --- head/sys/dev/flash/mx25l.c Sun Apr 17 01:38:37 2016 (r298135) +++ head/sys/dev/flash/mx25l.c Sun Apr 17 02:05:45 2016 (r298136) @@ -432,11 +432,13 @@ mx25l_set_4b_mode(device_t dev, uint8_t return (err); } +#ifdef FDT static struct ofw_compat_data compat_data[] = { { "st,m25p", 1 }, { "jedec,spi-nor", 1 }, { NULL, 0 }, }; +#endif static int mx25l_probe(device_t dev)