/* given the alg's descriptor header template, determine whether descriptor type and primary/secondary execution units required match the hw capabilities description provided in the device tree node.  */
static int hw_supports(struct device *dev, __be32 desc_hdr_template)
/* given the alg's descriptor header template, determine whether descriptor type and primary/secondary execution units required match the hw capabilities description provided in the device tree node.  */
static int hw_supports(struct device *dev, __be32 desc_hdr_template)
{
	struct talitos_private *priv = dev_get_drvdata(dev);
	int ret;
	ret = (1 << DESC_TYPE(desc_hdr_template) & priv->desc_types) &&
	      (1 << PRIMARY_EU(desc_hdr_template) & priv->exec_units);
	if (SECONDARY_EU(desc_hdr_template))
		ret = ret && (1 << SECONDARY_EU(desc_hdr_template)
		              & priv->exec_units);
	return ret;
}