Date: Wed, 17 Jun 2009 03:09:13 +0000 (UTC) From: Sam Leffler <sam@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r194325 - head/sys/arm/xscale/ixp425 Message-ID: <200906170309.n5H39Drr060683@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: sam Date: Wed Jun 17 03:09:13 2009 New Revision: 194325 URL: http://svn.freebsd.org/changeset/base/194325 Log: correct data/instruction memory sizes for non-ixp425 parts (these are only used to bounds-check writes when loading firmware) Modified: head/sys/arm/xscale/ixp425/ixp425_npe.c Modified: head/sys/arm/xscale/ixp425/ixp425_npe.c ============================================================================== --- head/sys/arm/xscale/ixp425/ixp425_npe.c Wed Jun 17 03:08:55 2009 (r194324) +++ head/sys/arm/xscale/ixp425/ixp425_npe.c Wed Jun 17 03:09:13 2009 (r194325) @@ -306,8 +306,14 @@ ixpnpe_attach(device_t dev, int npeid) sc->sc_nrefs = 1; sc->sc_size = config->size; - sc->insMemSize = config->ins_memsize; /* size of instruction memory */ - sc->dataMemSize = config->data_memsize; /* size of data memory */ + if (cpu_is_ixp42x()) { + /* NB: instruction/data memory sizes are NPE-dependent */ + sc->insMemSize = config->ins_memsize; + sc->dataMemSize = config->data_memsize; + } else { + sc->insMemSize = IXP46X_NPEDL_INS_MEMSIZE_WORDS; + sc->dataMemSize = IXP46X_NPEDL_DATA_MEMSIZE_WORDS; + } if (bus_space_map(sc->sc_iot, config->base, sc->sc_size, 0, &sc->sc_ioh)) panic("%s: Cannot map registers", device_get_name(dev));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906170309.n5H39Drr060683>