History

regmap: add i3c bus support

Add basic support for i3c bus. This is a simple implementation that only give support for SDR Read and Write commands.

Vitor Soares committed 7 years ago

Commit 64455001 parent a1883394 files · +86 −1Browse files

Showing the changes to include/linux (1 of 4 files). Show all

Unified · Split

include/linux/regmap.h+20−0
@@ -25,6 +25,7 @@ struct module; · 24 unmodified lines
2525 struct clk;
2626 struct device;
2727 struct i2c_client;
28+struct i3c_device;
2829 struct irq_domain;
2930 struct slim_device;
3031 struct spi_device;
@@ -624,6 +625,10 @@ struct regmap *__devm_regmap_init_slimbus(struct slim_device *slimbus, · 593 unmodified lines
624625 const struct regmap_config *config,
625626 struct lock_class_key *lock_key,
626627 const char *lock_name);
628+struct regmap *__devm_regmap_init_i3c(struct i3c_device *i3c,
629+ const struct regmap_config *config,
630+ struct lock_class_key *lock_key,
631+ const char *lock_name);
627632 /*
628633 * Wrapper for regmap_init macros to include a unique lockdep key and name
629634 * for each call. No-op if CONFIG_LOCKDEP is not set.
@@ -982,6 +987,21 @@ bool regmap_ac97_default_volatile(struct device *dev, unsigned int reg); · 352 unmodified lines
982987 #define devm_regmap_init_slimbus(slimbus, config) \
983988 __regmap_lockdep_wrapper(__devm_regmap_init_slimbus, #config, \
984989 slimbus, config)
990+
991+/**
992+ * devm_regmap_init_i3c() - Initialise managed register map
993+ *
994+ * @i3c: Device that will be interacted with
995+ * @config: Configuration for register map
996+ *
997+ * The return value will be an ERR_PTR() on error or a valid pointer
998+ * to a struct regmap. The regmap will be automatically freed by the
999+ * device management code.
1000+ */
1001+#define devm_regmap_init_i3c(i3c, config) \
1002+ __regmap_lockdep_wrapper(__devm_regmap_init_i3c, #config, \
1003+ i3c, config)
1004+
9851005 int regmap_mmio_attach_clk(struct regmap *map, struct clk *clk);
9861006 void regmap_mmio_detach_clk(struct regmap *map);
9871007 void regmap_exit(struct regmap *map);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t