pmic_class.h 503 B

12345678910111213141516171819
  1. #ifndef PMIC_CLASS_H
  2. #define PMIC_CLASS_H
  3. #if IS_ENABLED(CONFIG_DRV_SAMSUNG_PMIC)
  4. extern struct device *pmic_device_create(void *drvdata, const char *fmt);
  5. extern void pmic_device_destroy(dev_t devt);
  6. struct pmic_device_attribute {
  7. struct device_attribute dev_attr;
  8. };
  9. #define PMIC_ATTR(_name, _mode, _show, _store) \
  10. { .dev_attr = __ATTR(_name, _mode, _show, _store) }
  11. #else
  12. #define pmic_device_create(a, b) (-1)
  13. #define pmic_device_destroy(a) do { } while (0)
  14. #endif
  15. #endif /* PMIC_CLASS_H */