Home
last modified time | relevance | path

Searched full:hwmon (Results 1 – 25 of 504) sorted by relevance

12345678910>>...21

/Linux-v5.10/Documentation/ABI/stable/
Dsysfs-driver-mlxreg-io1 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/asic_health
10 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/cpld1_version
11 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/cpld2_version
20 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/fan_dir
30 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/cpld3_version
39 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/jtag_enable
48 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/select_iio
59 What: /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/psu1_on
60 /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/psu2_on
61 /sys/devices/platform/mlxplat/mlxreg-io/hwmon/hwmon*/pwr_cycle
[all …]
/Linux-v5.10/drivers/hwmon/
Dda9052-hwmon.c3 * HWMON Driver for Dialog DA9052
11 #include <linux/hwmon.h>
12 #include <linux/hwmon-sysfs.h>
67 static inline int input_tsireg_to_mv(struct da9052_hwmon *hwmon, int value) in input_tsireg_to_mv() argument
69 return DIV_ROUND_CLOSEST(value * hwmon->tsiref_mv, 1023); in input_tsireg_to_mv()
88 struct da9052_hwmon *hwmon = dev_get_drvdata(dev); in da9052_vddout_show() local
91 mutex_lock(&hwmon->hwmon_lock); in da9052_vddout_show()
93 ret = da9052_enable_vddout_channel(hwmon->da9052); in da9052_vddout_show()
97 vdd = da9052_reg_read(hwmon->da9052, DA9052_VDD_RES_REG); in da9052_vddout_show()
103 ret = da9052_disable_vddout_channel(hwmon->da9052); in da9052_vddout_show()
[all …]
Dgsc-hwmon.c7 #include <linux/hwmon.h>
8 #include <linux/hwmon-sysfs.h>
57 struct gsc_hwmon_data *hwmon = dev_get_drvdata(dev); in pwm_auto_point_temp_show() local
59 u8 reg = hwmon->pdata->fan_base + (2 * attr->index); in pwm_auto_point_temp_show()
63 ret = regmap_bulk_read(hwmon->regmap, reg, regs, 2); in pwm_auto_point_temp_show()
75 struct gsc_hwmon_data *hwmon = dev_get_drvdata(dev); in pwm_auto_point_temp_store() local
77 u8 reg = hwmon->pdata->fan_base + (2 * attr->index); in pwm_auto_point_temp_store()
90 err = regmap_bulk_write(hwmon->regmap, reg, regs, 2); in pwm_auto_point_temp_store()
149 struct gsc_hwmon_data *hwmon = dev_get_drvdata(dev); in gsc_hwmon_read() local
157 ch = hwmon->in_ch[channel]; in gsc_hwmon_read()
[all …]
Dnsa320-hwmon.c3 * drivers/hwmon/nsa320-hwmon.c
17 #include <linux/hwmon.h>
18 #include <linux/hwmon-sysfs.h>
31 * The Zyxel hwmon MCU is a Holtek HT46R065 that is factory programmed
72 struct nsa320_hwmon *hwmon = dev_get_drvdata(dev); in nsa320_hwmon_update() local
74 mutex_lock(&hwmon->update_lock); in nsa320_hwmon_update()
76 mcu_data = hwmon->mcu_data; in nsa320_hwmon_update()
78 if (time_after(jiffies, hwmon->last_updated + HZ) || mcu_data == 0) { in nsa320_hwmon_update()
79 gpiod_set_value(hwmon->act, 1); in nsa320_hwmon_update()
84 gpiod_set_value(hwmon->clk, 0); in nsa320_hwmon_update()
[all …]
Dda9055-hwmon.c3 * HWMON Driver for Dialog DA9055
12 #include <linux/hwmon.h>
13 #include <linux/hwmon-sysfs.h>
55 static int da9055_adc_manual_read(struct da9055_hwmon *hwmon, in da9055_adc_manual_read() argument
62 struct da9055 *da9055 = hwmon->da9055; in da9055_adc_manual_read()
67 mutex_lock(&hwmon->irq_lock); in da9055_adc_manual_read()
77 if (!wait_for_completion_timeout(&hwmon->done, in da9055_adc_manual_read()
102 mutex_unlock(&hwmon->irq_lock); in da9055_adc_manual_read()
108 struct da9055_hwmon *hwmon = irq_data; in da9055_auxadc_irq() local
110 complete(&hwmon->done); in da9055_auxadc_irq()
[all …]
Dsparx5-temp.c9 #include <linux/hwmon.h>
36 static void s5_temp_enable(struct s5_hwmon *hwmon) in s5_temp_enable() argument
38 u32 val = readl(hwmon->base + TEMP_CFG); in s5_temp_enable()
39 u32 clk = clk_get_rate(hwmon->clk) / USEC_PER_SEC; in s5_temp_enable()
45 writel(val, hwmon->base + TEMP_CFG); in s5_temp_enable()
51 struct s5_hwmon *hwmon = dev_get_drvdata(dev); in s5_read() local
57 stat = readl_relaxed(hwmon->base + TEMP_STAT); in s5_read()
68 * have millidegrees as specified by the hwmon sysfs in s5_read()
115 struct s5_hwmon *hwmon; in s5_temp_probe() local
118 hwmon = devm_kzalloc(&pdev->dev, sizeof(*hwmon), GFP_KERNEL); in s5_temp_probe()
[all …]
Ds3c-hwmon.c2 /* linux/drivers/hwmon/s3c-hwmon.c
8 * S3C24XX/S3C64XX ADC hwmon support
20 #include <linux/hwmon.h>
21 #include <linux/hwmon-sysfs.h>
24 #include <linux/platform_data/hwmon-s3c.h>
34 * struct s3c_hwmon - ADC hwmon client information
37 * @hwmon_dev: The hwmon device we created.
51 * @hwmon: Our state.
59 struct s3c_hwmon *hwmon, int channel) in s3c_hwmon_read_ch() argument
63 ret = mutex_lock_interruptible(&hwmon->lock); in s3c_hwmon_read_ch()
[all …]
Das370-hwmon.c10 #include <linux/hwmon.h>
31 static void init_pvt(struct as370_hwmon *hwmon) in init_pvt() argument
34 void __iomem *addr = hwmon->base + CTRL; in init_pvt()
50 struct as370_hwmon *hwmon = dev_get_drvdata(dev); in as370_hwmon_read() local
54 val = readl_relaxed(hwmon->base + STS) & BN_MASK; in as370_hwmon_read()
107 struct as370_hwmon *hwmon; in as370_hwmon_probe() local
110 hwmon = devm_kzalloc(dev, sizeof(*hwmon), GFP_KERNEL); in as370_hwmon_probe()
111 if (!hwmon) in as370_hwmon_probe()
114 hwmon->base = devm_platform_ioremap_resource(pdev, 0); in as370_hwmon_probe()
115 if (IS_ERR(hwmon->base)) in as370_hwmon_probe()
[all …]
Dsl28cpld-hwmon.c9 #include <linux/hwmon.h>
37 struct sl28cpld_hwmon *hwmon = dev_get_drvdata(dev); in sl28cpld_hwmon_read() local
43 ret = regmap_read(hwmon->regmap, hwmon->offset + FAN_INPUT, in sl28cpld_hwmon_read()
97 struct sl28cpld_hwmon *hwmon; in sl28cpld_hwmon_probe() local
104 hwmon = devm_kzalloc(&pdev->dev, sizeof(*hwmon), GFP_KERNEL); in sl28cpld_hwmon_probe()
105 if (!hwmon) in sl28cpld_hwmon_probe()
108 hwmon->regmap = dev_get_regmap(pdev->dev.parent, NULL); in sl28cpld_hwmon_probe()
109 if (!hwmon->regmap) in sl28cpld_hwmon_probe()
112 ret = device_property_read_u32(&pdev->dev, "reg", &hwmon->offset); in sl28cpld_hwmon_probe()
117 "sl28cpld_hwmon", hwmon, in sl28cpld_hwmon_probe()
[all …]
DMakefile6 obj-$(CONFIG_HWMON) += hwmon.o
7 obj-$(CONFIG_HWMON_VID) += hwmon-vid.o
50 obj-$(CONFIG_SENSORS_ARM_SCMI) += scmi-hwmon.o
51 obj-$(CONFIG_SENSORS_ARM_SCPI) += scpi-hwmon.o
52 obj-$(CONFIG_SENSORS_AS370) += as370-hwmon.o
60 obj-$(CONFIG_SENSORS_DA9052_ADC)+= da9052-hwmon.o
61 obj-$(CONFIG_SENSORS_DA9055)+= da9055-hwmon.o
62 obj-$(CONFIG_SENSORS_DELL_SMM) += dell-smm-hwmon.o
80 obj-$(CONFIG_SENSORS_GSC) += gsc-hwmon.o
93 obj-$(CONFIG_SENSORS_INTEL_M10_BMC_HWMON) += intel-m10-bmc-hwmon.o
[all …]
Dwm8350-hwmon.c3 * drivers/hwmon/wm8350-hwmon.c - Wolfson Microelectronics WM8350 PMIC
13 #include <linux/hwmon.h>
14 #include <linux/hwmon-sysfs.h>
83 .name = "wm8350-hwmon",
92 MODULE_ALIAS("platform:wm8350-hwmon");
/Linux-v5.10/drivers/thermal/
Dthermal_hwmon.c3 * thermal_hwmon.c - Generic Thermal Management hwmon support.
15 #include <linux/hwmon.h>
21 /* hwmon sys I/F */
22 /* thermal zone devices with the same type share one hwmon device */
40 struct thermal_hwmon_attr temp_input; /* hwmon sys attr */
41 struct thermal_hwmon_attr temp_crit; /* hwmon sys attr */
91 struct thermal_hwmon_device *hwmon; in thermal_hwmon_lookup_by_type() local
95 list_for_each_entry(hwmon, &thermal_hwmon_list, node) { in thermal_hwmon_lookup_by_type()
98 if (!strcmp(hwmon->type, type)) { in thermal_hwmon_lookup_by_type()
100 return hwmon; in thermal_hwmon_lookup_by_type()
[all …]
/Linux-v5.10/drivers/net/ethernet/sfc/
Dmcdi_mon.c9 #include <linux/hwmon.h>
146 struct efx_mcdi_mon *hwmon = efx_mcdi_mon(efx); in efx_mcdi_mon_update() local
151 hwmon->dma_buf.dma_addr); in efx_mcdi_mon_update()
152 MCDI_SET_DWORD(inbuf, READ_SENSORS_EXT_IN_LENGTH, hwmon->dma_buf.len); in efx_mcdi_mon_update()
157 hwmon->last_update = jiffies; in efx_mcdi_mon_update()
165 struct efx_mcdi_mon *hwmon = efx_mcdi_mon(efx); in efx_mcdi_mon_get_entry() local
170 mutex_lock(&hwmon->update_lock); in efx_mcdi_mon_get_entry()
173 if (time_before(jiffies, hwmon->last_update + HZ)) in efx_mcdi_mon_get_entry()
179 *entry = ((efx_dword_t *)hwmon->dma_buf.addr)[index]; in efx_mcdi_mon_get_entry()
181 mutex_unlock(&hwmon->update_lock); in efx_mcdi_mon_get_entry()
[all …]
/Linux-v5.10/Documentation/hwmon/
Dindex.rst8 hwmon-kernel-api
54 dell-smm-hwmon
68 gsc-hwmon
77 intel-m10-bmc-hwmon
151 raspberrypi-hwmon
154 scpi-hwmon
177 twl4030-madc-hwmon
195 xgene-hwmon
Dhwmon-kernel-api.rst12 This document does not describe what a hardware monitoring (hwmon) Driver or
15 then please read the following file: Documentation/hwmon/sysfs-interface.rst.
17 For additional guidelines on how to write and improve hwmon drivers, please
18 also read Documentation/hwmon/submitting-patches.rst.
22 Each hardware monitoring driver must #include <linux/hwmon.h> and, in most
23 cases, <linux/hwmon-sysfs.h>. linux/hwmon.h declares the following
55 The name parameter is a pointer to the hwmon device name. The registration
59 allocated hwmon device. The pointer can be retrieved by the driver using
60 dev_get_drvdata() on the hwmon device pointer. The groups parameter is
62 hwmon_device_register_with_groups creates the hwmon device with name attribute
[all …]
/Linux-v5.10/drivers/hwmon/occ/
DMakefile2 occ-hwmon-common-objs := common.o sysfs.o
3 occ-p8-hwmon-objs := p8_i2c.o
4 occ-p9-hwmon-objs := p9_sbe.o
6 obj-$(CONFIG_SENSORS_OCC) += occ-hwmon-common.o
7 obj-$(CONFIG_SENSORS_OCC_P8_I2C) += occ-p8-hwmon.o
8 obj-$(CONFIG_SENSORS_OCC_P9_SBE) += occ-p9-hwmon.o
/Linux-v5.10/Documentation/ABI/testing/
Dsysfs-platform-dfl-fme110 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/name
114 Description: Read-Only. Read this file to get the name of hwmon device, it
118 'dfl_fme_thermal' thermal hwmon device name
119 'dfl_fme_power' power hwmon device name
122 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_input
129 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_max
138 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_crit
146 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_emergency
155 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_max_alarm
162 What: /sys/bus/platform/devices/dfl-fme.0/hwmon/hwmonX/temp1_crit_alarm
[all …]
/Linux-v5.10/Documentation/devicetree/bindings/i2c/
Dibm,p8-occ-hwmon.txt1 Device-tree bindings for I2C-based On-Chip Controller hwmon device
5 - compatible = "ibm,p8-occ-hwmon";
16 occ-hwmon@1 {
17 compatible = "ibm,p8-occ-hwmon";
21 occ-hwmon@2 {
22 compatible = "ibm,p8-occ-hwmon";
/Linux-v5.10/arch/arm/boot/dts/
Daspeed-bmc-opp-mowgli.dts180 iio-hwmon-12v {
181 compatible = "iio-hwmon";
185 iio-hwmon-5v {
186 compatible = "iio-hwmon";
190 iio-hwmon-3v {
191 compatible = "iio-hwmon";
195 iio-hwmon-vdd {
196 compatible = "iio-hwmon";
200 iio-hwmon-vcs {
201 compatible = "iio-hwmon";
[all …]
Daspeed-bmc-opp-mihawk.dts237 iio-hwmon-12v {
238 compatible = "iio-hwmon";
242 iio-hwmon-5v {
243 compatible = "iio-hwmon";
247 iio-hwmon-3v {
248 compatible = "iio-hwmon";
252 iio-hwmon-vdd0 {
253 compatible = "iio-hwmon";
257 iio-hwmon-vdd1 {
258 compatible = "iio-hwmon";
[all …]
Daspeed-bmc-opp-vesnin.dts166 occ-hwmon@50 {
167 compatible = "ibm,p8-occ-hwmon";
175 occ-hwmon@51 {
176 compatible = "ibm,p8-occ-hwmon";
193 occ-hwmon@56 {
194 compatible = "ibm,p8-occ-hwmon";
210 occ-hwmon@57 {
211 compatible = "ibm,p8-occ-hwmon";
/Linux-v5.10/include/linux/platform_data/
Dhwmon-s3c.h7 * S3C - HWMon interface for ADC
20 * hwmon expects (mV) by result = (value_read * @mult) / @div.
29 * s3c_hwmon_pdata - HWMON platform data
37 * s3c_hwmon_set_platdata - Set platform data for S3C HWMON device
40 * Register the given platform data for use with the S3C HWMON device.
/Linux-v5.10/drivers/platform/mellanox/
Dmlxreg-io.c11 #include <linux/hwmon.h>
12 #include <linux/hwmon-sysfs.h>
28 * @hwmon: hwmon device;
32 * @groups: list of sysfs attribute group for hwmon registration;
38 struct device *hwmon; member
239 priv->hwmon = devm_hwmon_device_register_with_groups(&pdev->dev, in mlxreg_io_probe()
243 if (IS_ERR(priv->hwmon)) { in mlxreg_io_probe()
244 dev_err(&pdev->dev, "Failed to register hwmon device %ld\n", in mlxreg_io_probe()
245 PTR_ERR(priv->hwmon)); in mlxreg_io_probe()
246 return PTR_ERR(priv->hwmon); in mlxreg_io_probe()
/Linux-v5.10/drivers/gpu/drm/nouveau/
Dnouveau_hwmon.c29 #include <linux/hwmon.h>
30 #include <linux/hwmon-sysfs.h>
722 struct nouveau_hwmon *hwmon; in nouveau_hwmon_init() local
728 NV_DEBUG(drm, "Skipping hwmon registration\n"); in nouveau_hwmon_init()
732 hwmon = drm->hwmon = kzalloc(sizeof(*hwmon), GFP_KERNEL); in nouveau_hwmon_init()
733 if (!hwmon) in nouveau_hwmon_init()
735 hwmon->dev = dev; in nouveau_hwmon_init()
750 NV_ERROR(drm, "Unable to register hwmon device: %d\n", ret); in nouveau_hwmon_init()
754 hwmon->hwmon = hwmon_dev; in nouveau_hwmon_init()
765 struct nouveau_hwmon *hwmon = nouveau_hwmon(dev); in nouveau_hwmon_fini() local
[all …]
/Linux-v5.10/drivers/net/ethernet/intel/ixgbe/
Dixgbe_sysfs.c14 #include <linux/hwmon.h>
16 /* hwmon callback functions */
75 * ixgbe_add_hwmon_attr - Create hwmon attr table for a hwmon sysfs file.
80 * For each file we want in hwmon's sysfs interface we need a device_attribute
158 /* Don't create thermal hwmon interface if no sensors present */ in ixgbe_sysfs_init()
172 * Only create hwmon sysfs entries for sensors that have in ixgbe_sysfs_init()
178 /* Bail if any hwmon attr struct fails to initialize */ in ixgbe_sysfs_init()

12345678910>>...21