Lines Matching defs:priv
80 struct mmio_74xx_gpio_priv *priv = gpiochip_get_data(gc);
82 if (priv->flags & MMIO_74XX_DIR_OUT)
90 struct mmio_74xx_gpio_priv *priv = gpiochip_get_data(gc);
92 if (priv->flags & MMIO_74XX_DIR_IN)
100 struct mmio_74xx_gpio_priv *priv = gpiochip_get_data(gc);
102 if (priv->flags & MMIO_74XX_DIR_OUT) {
112 struct mmio_74xx_gpio_priv *priv;
116 priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL);
117 if (!priv)
120 priv->flags = (uintptr_t)device_get_match_data(&pdev->dev);
126 err = bgpio_init(&priv->gc, &pdev->dev,
127 DIV_ROUND_UP(MMIO_74XX_BIT_CNT(priv->flags), 8),
132 priv->gc.direction_input = mmio_74xx_dir_in;
133 priv->gc.direction_output = mmio_74xx_dir_out;
134 priv->gc.get_direction = mmio_74xx_get_direction;
135 priv->gc.ngpio = MMIO_74XX_BIT_CNT(priv->flags);
136 priv->gc.owner = THIS_MODULE;
138 return devm_gpiochip_add_data(&pdev->dev, &priv->gc, priv);