Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 02 Feb 2014 09:39:41 -0700
From:      Ian Lepore <ian@FreeBSD.org>
To:        =?ISO-8859-1?Q?Wei=DF=2C_J=FCrgen?= <weiss@uni-mainz.de>
Cc:        "'freebsd-arm@freebsd.org'" <freebsd-arm@FreeBSD.org>
Subject:   RE: status = "disabled"
Message-ID:  <1391359181.13026.18.camel@revolution.hippie.lan>
In-Reply-To: <06235e983f8142fcb7f6f6c329a84b90@e15be-01.zdv.Uni-Mainz.DE>
References:  <726dc97ccd1f44b3ba9d7bee3eeff08a@e15be-01.zdv.Uni-Mainz.DE> <52EE622C.9010004@freebsd.org> <06235e983f8142fcb7f6f6c329a84b90@e15be-01.zdv.Uni-Mainz.DE>

next in thread | previous in thread | raw e-mail | index | archive | help

--=-n7hzc6+iGE5ZRe14CnS4
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by damnhippie.dyndns.org id s12GdfFN062216

On Sun, 2014-02-02 at 15:59 +0000, Wei=DF, J=FCrgen wrote:
>=20
> > -----Original Message-----
> > From: Nathan Whitehorn [mailto:nwhitehorn@freebsd.org]
> > Sent: Sunday, February 02, 2014 4:20 PM
> > To: Wei=DF, J=FCrgen; freebsd-arm@freebsd.org
> > Subject: Re: status =3D "disabled"
> >=20
> > On 02/02/14 05:55, Wei=DF, J=FCrgen wrote:
> > > Hi,
> > >
> > > it seems your recent changes (261351) discarded a call to fdt_is_en=
abled
> > > for devices on simplebus. So 'status =3D "disabled" ' does not work
> > > anymore in arm dts.
> > >
> > > Regards
> > >
> > > Juergen Weiss
> > >
> > > Juergen Weiss      |Universitaet Mainz, Zentrum fuer Datenverarbeit=
ung,
> > > weiss@uni-mainz.de |55099 Mainz, Tel: +49(6131)39-26361, FAX: +49(6=
131)39-26407
> > >
> > >
> >=20
> > That's actually required to make some hardware work ("disabled" may j=
ust
> > mean the clock is turned off and needs to be turned back on, which me=
ans
> > you absolutely do want that device probed). The device drivers
> > themselves, not the bus, should be checking this property and
> > interpreting it. If this has actually broken hardware, we could add a
> > temporary #ifdef __arm__ check to the simplebus tree-walker while the
> > relevant drivers get fixed up.
> > -Nathan
>=20
>=20
> Thanks for the quick answer. Right know there seem to be zero device dr=
ivers
> doing this. And there are quite a few fdts going from general (all devi=
ces on SOC)=20
> to specific (devices usable on specific board), which use the status fi=
eld
> to disable a device (for example i.mx in general and wandboard specific=
ally).
> At least with the i.mx6 the unconnected sdhci devices lead to hangs dur=
ing
> boot.

Here is a little patch to get you running again in the short term.  I'm
going to see if I can make a pass through all our drivers and fix things
the right way.  If I can't get that done in a hurry (today, basically),
we'll commit something like this patch for the short term.

-- Ian



--=-n7hzc6+iGE5ZRe14CnS4
Content-Disposition: inline; filename="aicasm_stab8.diff"
Content-Type: text/x-patch; name="aicasm_stab8.diff"; charset="us-ascii"
Content-Transfer-Encoding: 7bit

Index: Makefile.inc1
===================================================================
--- Makefile.inc1	(revision 261326)
+++ Makefile.inc1	(working copy)
@@ -250,6 +250,21 @@ XMAKE=		TOOLS_PREFIX=${WORLDTMP} ${BMAKE} \
 		TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \
 		-DWITHOUT_GDB
 
+# kernel-tools stage
+KTMAKEENV=	INSTALL="sh ${.CURDIR}/tools/install.sh" \
+		PATH=${BPATH}:${PATH} \
+		WORLDTMP=${WORLDTMP} \
+		VERSION="${VERSION}" \
+		COMPILER_TYPE=${COMPILER_TYPE}
+KTMAKE=		TOOLS_PREFIX=${WORLDTMP} MAKEOBJDIRPREFIX=${WORLDTMP} \
+		${KTMAKEENV} ${MAKE} ${WORLD_FLAGS} -f Makefile.inc1 \
+		DESTDIR= \
+		BOOTSTRAPPING=${OSRELDATE} \
+		SSP_CFLAGS= \
+		-DWITHOUT_HTML -DWITHOUT_INFO -DNO_LINT -DWITHOUT_MAN \
+		-DNO_PIC -DNO_PROFILE -DNO_SHARED \
+		-DNO_CPU_CFLAGS -DNO_WARNS -DNO_CTF -DEARLY_BUILD
+
 # world stage
 WMAKEENV=	${CROSSENV} \
 		_SHLIBDIRPREFIX=${WORLDTMP} \
@@ -403,6 +418,7 @@ _cross-tools:
 	@echo ">>> stage 3: cross tools"
 	@echo "--------------------------------------------------------------"
 	${_+_}cd ${.CURDIR}; ${XMAKE} cross-tools
+	${_+_}cd ${.CURDIR}; ${XMAKE} kernel-tools
 _includes:
 	@echo
 	@echo "--------------------------------------------------------------"
@@ -776,20 +792,7 @@ buildkernel:
 	@echo "--------------------------------------------------------------"
 	@echo ">>> stage 2.3: build tools"
 	@echo "--------------------------------------------------------------"
-	cd ${KRNLOBJDIR}/${_kernel}; \
-	    PATH=${BPATH}:${PATH} \
-	    MAKESRCPATH=${KERNSRCDIR}/dev/aic7xxx/aicasm \
-	    ${MAKE} SSP_CFLAGS= -DNO_CPU_CFLAGS -DNO_CTF \
-	    -f ${KERNSRCDIR}/dev/aic7xxx/aicasm/Makefile
-# XXX - Gratuitously builds aicasm in the ``makeoptions NO_MODULES'' case.
-.if !defined(MODULES_WITH_WORLD) && !defined(NO_MODULES) && exists(${KERNSRCDIR}/modules)
-.for target in obj depend all
-	cd ${KERNSRCDIR}/modules/aic7xxx/aicasm; \
-	    PATH=${BPATH}:${PATH} \
-	    MAKEOBJDIRPREFIX=${KRNLOBJDIR}/${_kernel}/modules \
-	    ${MAKE} SSP_CFLAGS= -DNO_CPU_CFLAGS -DNO_CTF ${target}
-.endfor
-.endif
+	${_+_}cd ${.CURDIR}; ${KTMAKE} kernel-tools
 .if !defined(NO_KERNELDEPEND)
 	@echo
 	@echo "--------------------------------------------------------------"
@@ -1003,10 +1006,6 @@ bootstrap-tools:
 #
 # build-tools: Build special purpose build tools
 #
-.if defined(MODULES_WITH_WORLD) && exists(${KERNSRCDIR}/modules)
-_aicasm= sys/modules/aic7xxx/aicasm
-.endif
-
 .if !defined(NO_SHARE)
 _share=	share/syscons/scrnmaps
 .endif
@@ -1027,7 +1026,6 @@ build-tools:
     lib/ncurses/ncurses \
     lib/ncurses/ncursesw \
     ${_share} \
-    ${_aicasm} \
     usr.bin/awk \
     lib/libmagic \
     usr.sbin/sysinstall
@@ -1047,6 +1045,23 @@ build-tools:
 .endfor
 
 #
+# kernel-tools: Build kernel-building tools
+#
+kernel-tools: .MAKE
+	mkdir -p ${MAKEOBJDIRPREFIX}/usr
+	mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \
+	    -p ${MAKEOBJDIRPREFIX}/usr >/dev/null
+.for _tool in \
+    sys/dev/aic7xxx/aicasm
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \
+		cd ${.CURDIR}/${_tool} && \
+		${MAKE} DIRPRFX=${_tool}/ obj && \
+		${MAKE} DIRPRFX=${_tool}/ depend && \
+		${MAKE} DIRPRFX=${_tool}/ all && \
+		${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX} install
+.endfor
+
+#
 # cross-tools: Build cross-building tools
 #
 .if ${TARGET_ARCH} != ${MACHINE_ARCH} || ${BOOTSTRAPPING} < 800035
Index: sys/modules/aic7xxx/ahc/Makefile
===================================================================
--- sys/modules/aic7xxx/ahc/Makefile	(revision 261326)
+++ sys/modules/aic7xxx/ahc/Makefile	(working copy)
@@ -15,13 +15,10 @@ REG_PRINT_OPT= -p aic7xxx_reg_print.c
 .endif
 BEFORE_DEPEND = ${GENSRCS}
 
-../aicasm/aicasm: ${.CURDIR}/../../../dev/aci7xxx/aicasm/*.[chyl]
-	( cd ${.CURDIR}/../aicasm; ${MAKE} aicasm; )
-
 ${GENSRCS}:								 \
 		${.CURDIR}/../../../dev/aic7xxx/aic7xxx.{reg,seq}	 \
-		${.CURDIR}/../../../cam/scsi/scsi_message.h ../aicasm/aicasm
-	../aicasm/aicasm ${INCLUDES} -I${.CURDIR}/../../../cam/scsi	 \
+		${.CURDIR}/../../../cam/scsi/scsi_message.h 
+	aicasm ${INCLUDES} -I${.CURDIR}/../../../cam/scsi	 \
 			-I${.CURDIR}/../../../dev/aic7xxx		 \
 			-o aic7xxx_seq.h -r aic7xxx_reg.h		 \
 			${REG_PRINT_OPT}				 \
Index: sys/modules/aic7xxx/ahd/Makefile
===================================================================
--- sys/modules/aic7xxx/ahd/Makefile	(revision 261326)
+++ sys/modules/aic7xxx/ahd/Makefile	(working copy)
@@ -15,13 +15,10 @@ REG_PRINT_OPT= -p aic79xx_reg_print.c
 .endif
 BEFORE_DEPEND= ${GENSRCS}
 
-../aicasm/aicasm: ${.CURDIR}/../../../dev/aic7xxx/aicasm/*.[chyl]
-	( cd ${.CURDIR}/../aicasm; ${MAKE} aicasm; )
-
 ${GENSRCS}:								 \
 		${.CURDIR}/../../../dev/aic7xxx/aic79xx.{reg,seq}	 \
-		${.CURDIR}/../../../cam/scsi/scsi_message.h ../aicasm/aicasm
-	../aicasm/aicasm ${INCLUDES} -I${.CURDIR}/../../../cam/scsi	 \
+		${.CURDIR}/../../../cam/scsi/scsi_message.h
+	aicasm ${INCLUDES} -I${.CURDIR}/../../../cam/scsi	 \
 			-I${.CURDIR}/../../../dev/aic7xxx		 \
 			-o aic79xx_seq.h -r aic79xx_reg.h		 \
 			${REG_PRINT_OPT}				 \
Index: sys/modules/aic7xxx/Makefile
===================================================================
--- sys/modules/aic7xxx/Makefile	(revision 261326)
+++ sys/modules/aic7xxx/Makefile	(working copy)
@@ -1,6 +1,6 @@
 
 # $FreeBSD$
 
-SUBDIR= aicasm ahc ahd
+SUBDIR= ahc ahd
 
 .include <bsd.subdir.mk>
Index: sys/conf/files
===================================================================
--- sys/conf/files	(revision 261326)
+++ sys/conf/files	(working copy)
@@ -9,44 +9,39 @@ acpi_quirks.h			optional acpi				   \
 	compile-with	"${AWK} -f $S/tools/acpi_quirks2h.awk $S/dev/acpica/acpi_quirks" \
 	no-obj no-implicit-rule before-depend				   \
 	clean		"acpi_quirks.h"
-aicasm				optional ahc | ahd			   \
-	dependency	"$S/dev/aic7xxx/aicasm/*.[chyl]"		   \
-	compile-with	"CC='${CC}' ${MAKE} -f $S/dev/aic7xxx/aicasm/Makefile MAKESRCPATH=$S/dev/aic7xxx/aicasm" \
-	no-obj no-implicit-rule						   \
-	clean		"aicasm* y.tab.h"
 aic7xxx_seq.h			optional ahc				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
 	no-obj no-implicit-rule before-depend local			   \
 	clean		"aic7xxx_seq.h"					   \
-	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic7xxx_reg.h			optional ahc				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
 	no-obj no-implicit-rule before-depend local			   \
 	clean		"aic7xxx_reg.h"					   \
-	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic7xxx_reg_print.c		optional ahc				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic7xxx_seq.h -r aic7xxx_reg.h -p aic7xxx_reg_print.c -i $S/dev/aic7xxx/aic7xxx_osm.h $S/dev/aic7xxx/aic7xxx.seq"   \
 	no-obj no-implicit-rule local					   \
 	clean		"aic7xxx_reg_print.c"				   \
-	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic7xxx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic7xxx_reg_print.o		optional ahc ahc_reg_pretty_print	   \
 	compile-with	"${NORMAL_C}"					   \
 	no-implicit-rule local
 aic79xx_seq.h		optional ahd pci				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
 	no-obj no-implicit-rule before-depend local			   \
 	clean		"aic79xx_seq.h"					   \
-	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic79xx_reg.h		optional ahd pci				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
 	no-obj no-implicit-rule before-depend local			   \
 	clean		"aic79xx_reg.h"					   \
-	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic79xx_reg_print.c	optional ahd pci				   \
-	compile-with	"./aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
+	compile-with	"aicasm ${INCLUDES} -I$S/cam/scsi -I$S/dev/aic7xxx -o aic79xx_seq.h -r aic79xx_reg.h -p aic79xx_reg_print.c -i $S/dev/aic7xxx/aic79xx_osm.h $S/dev/aic7xxx/aic79xx.seq"   \
 	no-obj no-implicit-rule local					   \
 	clean		"aic79xx_reg_print.c"				   \
-	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h aicasm"
+	dependency	"$S/dev/aic7xxx/aic79xx.{reg,seq} $S/cam/scsi/scsi_message.h"
 aic79xx_reg_print.o		optional ahd pci ahd_reg_pretty_print	   \
 	compile-with	"${NORMAL_C}"					   \
 	no-implicit-rule local
Index: sys/dev/aic7xxx/aicasm/Makefile
===================================================================
--- sys/dev/aic7xxx/aicasm/Makefile	(revision 261326)
+++ sys/dev/aic7xxx/aicasm/Makefile	(working copy)
@@ -15,7 +15,7 @@ SRCS=	${GENHDRS} ${CSRCS} ${YSRCS} ${LSRCS}
 CLEANFILES+= ${GENHDRS} ${YSRCS:R:C/(.*)/\1.output/g}
 DPADD=	${LIBL}
 LDADD=	-ll
-WARNS?=	6
+WARNS?=	0
 
 # Correct path for kernel builds
 # Don't rely on the kernel's .depend file
@@ -24,13 +24,7 @@ LDADD=	-ll
 DEPENDFILE=	.depend_aicasm
 .endif
 
-.if ${CC} == "icc"
-CFLAGS+=	-restrict
-NOSTDINC=	-X
-.else
-NOSTDINC=	-nostdinc
-.endif
-CFLAGS+= ${NOSTDINC} -I/usr/include -I.
+CFLAGS+= -I${.CURDIR}
 .ifdef MAKESRCPATH
 CFLAGS+= -I${MAKESRCPATH}
 .endif
@@ -44,4 +38,8 @@ YFLAGS+= -t -v
 LFLAGS+= -d
 .endif
 
+BINDIR=/usr/bin
+
+build-tools: ${PROG}
+
 .include <bsd.prog.mk>

--=-n7hzc6+iGE5ZRe14CnS4--




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1391359181.13026.18.camel>