3 * (C) Copyright 2014 Freescale Semiconductor, Inc
5 * SPDX-License-Identifier: GPL-2.0+
13 int thermal_get_temp(struct udevice *dev, int *temp);
16 * struct struct dm_thermal_ops - Driver model Thermal operations
18 * The uclass interface is implemented by all Thermal devices which use
21 struct dm_thermal_ops {
23 * Get the current temperature
25 * The device provided is the slave device. It's parent controller
26 * will be used to provide the communication.
28 * This must be called before doing any transfers with a Thermal slave.
29 * It will enable and initialize any Thermal hardware as necessary,
30 * and make sure that the SCK line is in the correct idle state. It is
31 * not allowed to claim the same bus for several slaves without
32 * releasing the bus in between.
34 * @dev: The Thermal device
36 * Returns: 0 if the bus was claimed successfully, or a negative value
39 int (*get_temp)(struct udevice *dev, int *temp);
42 #endif /* _THERMAL_H_ */