Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   1) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   2)  * Copyright (c) 2017 Rockchip Electronics Co. Ltd.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   3)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   4)  * This program is free software; you can redistribute it and/or modify
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   5)  * it under the terms of the GNU General Public License as published by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   6)  * the Free Software Foundation; either version 2 of the License, or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   7)  * (at your option) any later version.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   8)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   9)  * This program is distributed in the hope that it will be useful,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  10)  * but WITHOUT ANY WARRANTY; without even the implied warranty of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  11)  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  12)  * GNU General Public License for more details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  13)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  14) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  15) #include <linux/module.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  16) #include <linux/init.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  17) #include <linux/i2c.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  18) #include <linux/gpio/consumer.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  19) #include <linux/pinctrl/consumer.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  20) #include <linux/regulator/consumer.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  21) #include <linux/mfd/core.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  22) #include <linux/mfd/rk618.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  23) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  24) static const struct mfd_cell rk618_devs[] = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  25) 	{
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  26) 		.name = "rk618-codec",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  27) 		.of_compatible = "rockchip,rk618-codec",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  28) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  29) 		.name = "rk618-cru",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  30) 		.of_compatible = "rockchip,rk618-cru",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  31) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  32) 		.name = "rk618-dsi",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  33) 		.of_compatible = "rockchip,rk618-dsi",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  34) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  35) 		.name = "rk618-hdmi",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  36) 		.of_compatible = "rockchip,rk618-hdmi",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  37) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  38) 		.name = "rk618-lvds",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  39) 		.of_compatible = "rockchip,rk618-lvds",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  40) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  41) 		.name = "rk618-rgb",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  42) 		.of_compatible = "rockchip,rk618-rgb",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  43) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  44) 		.name = "rk618-scaler",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  45) 		.of_compatible = "rockchip,rk618-scaler",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  46) 	}, {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  47) 		.name = "rk618-vif",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  48) 		.of_compatible = "rockchip,rk618-vif",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  49) 	},
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  50) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  51) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  52) static int rk618_power_on(struct rk618 *rk618)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  53) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  54) 	u32 reg;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  55) 	int ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  56) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  57) 	ret = regulator_enable(rk618->supply);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  58) 	if (ret < 0) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  59) 		dev_err(rk618->dev, "failed to enable supply: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  60) 		return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  61) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  62) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  63) 	if (rk618->enable_gpio)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  64) 		gpiod_direction_output(rk618->enable_gpio, 1);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  65) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  66) 	usleep_range(1000, 2000);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  67) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  68) 	ret = regmap_read(rk618->regmap, 0x0000, &reg);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  69) 	if (ret) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  70) 		gpiod_direction_output(rk618->reset_gpio, 0);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  71) 		usleep_range(2000, 4000);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  72) 		gpiod_direction_output(rk618->reset_gpio, 1);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  73) 		usleep_range(50000, 60000);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  74) 		gpiod_direction_output(rk618->reset_gpio, 0);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  75) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  76) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  77) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  78) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  79) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  80) static void rk618_power_off(struct rk618 *rk618)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  81) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  82) 	gpiod_direction_output(rk618->reset_gpio, 1);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  83) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  84) 	if (rk618->enable_gpio)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  85) 		gpiod_direction_output(rk618->enable_gpio, 0);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  86) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  87) 	regulator_disable(rk618->supply);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  88) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  89) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  90) static const struct regmap_config rk618_regmap_config = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  91) 	.name = "core",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  92) 	.reg_bits = 16,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  93) 	.val_bits = 32,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  94) 	.reg_stride = 4,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  95) 	.max_register = 0x9c,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  96) 	.reg_format_endian = REGMAP_ENDIAN_NATIVE,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  97) 	.val_format_endian = REGMAP_ENDIAN_NATIVE,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  98) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  99) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100) static int
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101) rk618_probe(struct i2c_client *client, const struct i2c_device_id *id)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103) 	struct device *dev = &client->dev;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104) 	struct rk618 *rk618;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105) 	int ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107) 	rk618 = devm_kzalloc(dev, sizeof(*rk618), GFP_KERNEL);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108) 	if (!rk618)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109) 		return -ENOMEM;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111) 	rk618->dev = dev;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112) 	rk618->client = client;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113) 	i2c_set_clientdata(client, rk618);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115) 	rk618->supply = devm_regulator_get(dev, "power");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116) 	if (IS_ERR(rk618->supply))
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117) 		return PTR_ERR(rk618->supply);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119) 	rk618->enable_gpio = devm_gpiod_get_optional(dev, "enable", 0);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 120) 	if (IS_ERR(rk618->enable_gpio)) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 121) 		ret = PTR_ERR(rk618->enable_gpio);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 122) 		dev_err(dev, "failed to request enable GPIO: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 123) 		return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 124) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 125) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 126) 	rk618->reset_gpio = devm_gpiod_get(dev, "reset", 0);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 127) 	if (IS_ERR(rk618->reset_gpio)) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 128) 		ret = PTR_ERR(rk618->reset_gpio);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 129) 		dev_err(dev, "failed to request reset GPIO: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 130) 		return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 131) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 132) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 133) 	rk618->clkin = devm_clk_get(dev, "clkin");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 134) 	if (IS_ERR(rk618->clkin)) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 135) 		dev_err(dev, "failed to get clock\n");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 136) 		return PTR_ERR(rk618->clkin);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 137) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 138) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 139) 	ret = clk_prepare_enable(rk618->clkin);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 140) 	if (ret) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 141) 		dev_err(dev, "unable to enable clock: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 142) 		return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 143) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 144) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 145) 	rk618->regmap = devm_regmap_init_i2c(client, &rk618_regmap_config);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 146) 	if (IS_ERR(rk618->regmap)) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 147) 		ret = PTR_ERR(rk618->regmap);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 148) 		dev_err(dev, "failed to allocate register map: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 149) 		goto err_clk_disable;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 150) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 151) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 152) 	ret = rk618_power_on(rk618);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 153) 	if (ret)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 154) 		goto err_clk_disable;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 155) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 156) 	ret = mfd_add_devices(dev, -1, rk618_devs, ARRAY_SIZE(rk618_devs),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 157) 			      NULL, 0, NULL);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 158) 	if (ret) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 159) 		dev_err(dev, "failed to add subdev: %d\n", ret);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 160) 		goto err_clk_disable;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 161) 	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 162) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 163) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 164) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 165) err_clk_disable:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 166) 	clk_disable_unprepare(rk618->clkin);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 167) 	return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 168) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 169) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 170) static int rk618_remove(struct i2c_client *client)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 171) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 172) 	struct rk618 *rk618 = i2c_get_clientdata(client);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 173) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 174) 	mfd_remove_devices(rk618->dev);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 175) 	rk618_power_off(rk618);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 176) 	clk_disable_unprepare(rk618->clkin);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 177) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 178) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 179) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 180) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 181) static void rk618_shutdown(struct i2c_client *client)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 182) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 183) 	struct rk618 *rk618 = i2c_get_clientdata(client);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 184) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 185) 	rk618_power_off(rk618);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 186) 	clk_disable_unprepare(rk618->clkin);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 187) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 188) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 189) static int __maybe_unused rk618_suspend(struct device *dev)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 190) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 191) 	pinctrl_pm_select_sleep_state(dev);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 192) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 193) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 194) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 195) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 196) static int __maybe_unused rk618_resume(struct device *dev)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 197) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 198) 	pinctrl_pm_select_default_state(dev);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 199) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 200) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 201) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 202) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 203) static const struct dev_pm_ops rk618_pm_ops = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 204) 	SET_SYSTEM_SLEEP_PM_OPS(rk618_suspend, rk618_resume)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 205) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 206) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 207) static const struct of_device_id rk618_of_match[] = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 208) 	{ .compatible = "rockchip,rk618", },
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 209) 	{}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 210) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 211) MODULE_DEVICE_TABLE(of, rk618_of_match);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 212) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 213) static const struct i2c_device_id rk618_i2c_id[] = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 214) 	{ "rk618", 0 },
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 215) 	{}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 216) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 217) MODULE_DEVICE_TABLE(i2c, rk618_i2c_id);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 218) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 219) static struct i2c_driver rk618_driver = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 220) 	.driver = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 221) 		.name = "rk618",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 222) 		.of_match_table = of_match_ptr(rk618_of_match),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 223) 		.pm = &rk618_pm_ops,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 224) 	},
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 225) 	.probe = rk618_probe,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 226) 	.remove = rk618_remove,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 227) 	.shutdown = rk618_shutdown,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 228) 	.id_table = rk618_i2c_id,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 229) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 230) module_i2c_driver(rk618_driver);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 231) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 232) MODULE_AUTHOR("Wyon Bi <bivvy.bi@rock-chips.com>");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 233) MODULE_DESCRIPTION("Rockchip rk618 i2c driver");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 234) MODULE_LICENSE("GPL v2");