lib/sw_apps/zynqmp_pmufw/src/pm_slave.c
s32 PmSlaveVerifyRequest(const PmSlave* const slave)
{
	s32 status = XST_SUCCESS;
	u32 usage;

	/* If slave is shareable the request is ok */
	if (0U != (PM_SLAVE_FLAG_IS_SHAREABLE & slave->flags)) {
		goto done;
	}

	usage = PmSlaveGetUsersMask(slave);
	/* Slave is not shareable, if it is unused the request is ok */
	if (0U == usage) {
		goto done;
	}

	/* Slave request cannot be granted, node is non-shareable and used */
	status = XST_PM_NODE_USED;

done:
	return status;
}
/**
 * PmSlaveVerifyRequest() - Check whether PM framework can grant the request
 * @slave       Slave node that is requested
 *
 * @return      XST_SUCCESS if the following condition is satisfied : (slave
 *              is shareable) OR (it is exclusively used AND no other master
 *              currently uses the slave)
 *              XST_PM_NODE_USED otherwise
 */
Check whether PM framework can grant the request
@slave       Slave node that is requested

@return      XST_SUCCESS if the following condition is satisfied : (slave
is shareable) OR (it is exclusively used AND no other master
currently uses the slave)
XST_PM_NODE_USED otherwise
Check whether PM framework can grant the request @slave Slave node that is requested @return XST_SUCCESS if the following condition is satisfied : ( slave is shareable ) OR ( it is exclusively used AND no other master currently uses the slave ) XST_PM_NODE_USED otherwise
s32 PmSlaveVerifyRequest(const PmSlave* const slave)
{
	s32 status = XST_SUCCESS;
	u32 usage;
	if (0U != (PM_SLAVE_FLAG_IS_SHAREABLE & slave->flags)) {
		goto done;
	}
	usage = PmSlaveGetUsersMask(slave);
	if (0U == usage) {
		goto done;
	}
	status = XST_PM_NODE_USED;
done:
	return status;
}
s32 PmSlaveVerifyRequest ( const PmSlave * const slave ) { s32 status = XST_SUCCESS ; u32 usage ; if ( 0U != ( PM_SLAVE_FLAG_IS_SHAREABLE & slave -> flags ) ) { goto done ; } usage = PmSlaveGetUsersMask ( slave ) ; if ( 0U == usage ) { goto done ; } status = XST_PM_NODE_USED ; done : return status ; }
PmSlaveVerifyRequest() - Check whether PM framework can grant the request
 @slave       Slave node that is requested
PmSlaveVerifyRequest () - Check whether PM framework can grant the request @slave Slave node that is requested
/* If slave is shareable the request is ok */ /* Slave is not shareable, if it is unused the request is ok */ /* Slave request cannot be granted, node is non-shareable and used */