%' *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
%'  TRIM(a) - returns the input parameter trimmed of leading and
%'	 trailing blanks.
%*DEFINE(TRIM(a)) LOCAL x y (%MATCH( x y)(%a)%x)%'
%' *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
%'   ARG -  gets the next comma-delimited arg from variable named TAIL,
%'	stripped and trimmed.  Any macro that has a valid type of NONE
%'	uses this macro so that the other parameters are not needed.
%*DEFINE(ARG) LOCAL a (%MATCH(a,tail)(%tail)%TRIM(%a))%'
%' *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

%*DEFINE(BSCSI(parameters))(%DEFINE(tail)(%parameters)%' 
	name	bscsi

	public	aport_scsi, bport_scsi, cport_scsi, controlport_scsi
	public	hostid_scsi, arbitrate_scsi, dmacontrol_scsi
	public	dmachannel_scsi, dmabaseaddr_scsi, dmaseparation_scsi
	public	dmamultiplexport_scsi
		

code_bscsi	segment	byte public 'CODE'
aport_scsi		dw	%ARG
bport_scsi		dw	%ARG
cport_scsi		dw	%ARG
controlport_scsi	dw	%ARG
hostid_scsi		db	%ARG
arbitrate_scsi		db	%ARG
dmacontrol_scsi		db	%ARG
dmachannel_scsi		db	%ARG
dmabaseaddr_scsi	dw	%ARG
dmaseparation_scsi	db	%ARG
%'
%DEFINE(din)(%ARG)%'
dma_info		db	%din
%'
%DEFINE(mux)(%ARG)%'
%IF ((%LEN (%mux) EQ 0) OR (%din EQ 0)) THEN (%DEFINE(mux)(0))FI%'
%'
dmamultiplexport_scsi	dw	%mux

code_bscsi	ends

)	%' end of the BSCSI macro

%' *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

%*DEFINE(SASI_UNIT_INFO(parameters))(%DEFINE(tail)(%parameters)%' 

%DEFINE(uinfo_name)(%ARG)%'

		public	%uinfo_name
		
assume cs: code_bscsi

code_bscsi	segment	byte public 'CODE'

%uinfo_name:
		db	%ARG	; init_command
		db	%ARG	; init_count

%DEFINE (init)(%ARG)%'

%WHILE (%LEN (%init) ne 0)(%' 
		db	%init
%'	'%DEFINE (init)(%ARG)%'
)%'

code_bscsi	ends

assume cs: nothing
) %'end SASI_UNIT_INFO macro
