sys/dev/mfi/mfi_tbolt.c
/*
 * This function calculates the memory requirement for Thunderbolt
 * controller, returns the total required memory in bytes
 */
This function calculates the memory requirement for Thunderbolt
controller, returns the total required memory in bytes
This function calculates the memory requirement for Thunderbolt controller returns the total required memory in bytes
uint32_t
mfi_tbolt_get_memory_requirement(struct mfi_softc *sc)
{
	uint32_t size;
	size = MEGASAS_THUNDERBOLT_MSG_ALLIGNMENT;	
	size += sc->raid_io_msg_size * (sc->mfi_max_fw_cmds + 1);
	size += sc->reply_size * sc->mfi_max_fw_cmds;
	size += MEGASAS_MAX_SZ_CHAIN_FRAME * sc->mfi_max_fw_cmds;
	return size;
}
uint32_t mfi_tbolt_get_memory_requirement ( struct mfi_softc * sc ) { uint32_t size ; size = MEGASAS_THUNDERBOLT_MSG_ALLIGNMENT ; size += sc -> raid_io_msg_size * ( sc -> mfi_max_fw_cmds + 1 ) ; size += sc -> reply_size * sc -> mfi_max_fw_cmds ; size += MEGASAS_MAX_SZ_CHAIN_FRAME * sc -> mfi_max_fw_cmds ; return size ; }
This function calculates the memory requirement for Thunderbolt
 controller, returns the total required memory in bytes
This function calculates the memory requirement for Thunderbolt controller returns the total required memory in bytes
/* for Alignment */ /* this is for SGL's */