dev_err(priv->dev, "Failed to power off the system");
return NOTIFY_DONE;
}
staticint rzv2m_pwc_probe(struct platform_device *pdev)
{ struct rzv2m_pwc_priv *priv; int ret;
priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); if (!priv) return -ENOMEM;
priv->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->base)) return PTR_ERR(priv->base);
/* * The register used by this driver cannot be read, therefore set the * outputs to their default values and initialize priv->ch_en_bits * accordingly. BIT 16 enables write to BIT 0, BIT 17 enables write to * BIT 1, and the default value of both BIT 0 and BIT 1 is 0.
*/
writel(BIT(17) | BIT(16), priv->base + PWC_GPIO);
bitmap_zero(priv->ch_en_bits, 2);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.