Introduce MEN 14F021P00 BMC driver series
Subsystems (6)
Andreas Werner
maintainerv6 cover Introduce MEN 14F021P00 BMC driver series
This patch set add support for the MEN 14F021P00 Board Management called BMC.
The BMC is a PIC Mikrocontroller which assembled on almost all of our 3U Compact PCI CPU board and a few Box PCs.
main part of the BMC is to start and monitor the board, but there are a lot more features which can be accessed using an I2C Host interface
Features supported in this Patchset:
- Watchdog
- LEDs
- HWMON
The Patchset includes a MFD Core driver, Watchdog, hwmon and LEDs driver.
Changes in v6:
- fixed some style issues (80 chars, whitespaces, alignment)
- fixed error handling in update function of hwmon slave
- fixed whitespace error in hwmon documentation
- added module name in each of the Kconfigs
Changes in v5:
- fixed I2C dependency in MFD Kconfig
- added correct error handling in update function of the hwmon slave (Use of ERR_PTR)
- add ATTRIBUTE_GROUP Macro in hwmon slave
and deleted platform_set_drvdata
Changes in v4:
- fixed some style issues
- fixed GPL license version
- added hwmon voltage monitoring slave driver
Changes in v3:
- deleted i2c_smbus wrapper functions and use native one
- some cosmentics and variable renaming to be more clear
- renamed "leave production" mode to "exit production mode"
Changes in v2:
- changed i2c_smbus_read wrapper function to return both, value and error.
- moved "leave production mode" from Watchdog driver to mfd core.
- fixed some return values in the watchdog driver to return the original error value instead of -EIO.
Andreas Werner (4):
drivers/mfd/menf21bmc: introduce MEN 14F021P00 BMC MFD Core driver drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog
driver
drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver drivers/hwmon/menf21bmc_hwmon: introduce MEN14F021P00 BMC HWMON driver
Documentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c
Signature · 1 line
2.0.4
Andreas Werner
maintainerPATCH v6 1/4 drivers/mfd/menf21bmc: introduce MEN 14F021P00 BMC MFD Core driver
The MEN 14F021P00 Board Management Controller provides an
I2C interface to the host to access the feature implemented in the BMC. The BMC is a PIC Microntroller assembled on CPCI Card from MEN Mikroelektronik and on a few Box/Display Computer.
Added MFD Core driver, supporting the I2C communication to the device.
The MFD driver currently supports the following features:
- Watchdog
- LEDs
- Hwmon (voltage monitoring)
--- drivers/mfd/Kconfig | 15 ++++++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 148 insertions(+) create mode 100644 drivers/mfd/menf21bmc.c
drivers/mfd/Kconfig +15 -0
@@ -453,6 +453,21 @@ config MFD_MAX8998 additional drivers must be enabled in order to use the functionality of the device. +config MFD_MENF21BMC + tristate "MEN 14F021P00 Board Management Controller Support" + depends on I2C + select MFD_CORE + help + Say yes here to add support for the MEN 14F021P00 BMC + which is a Board Management Controller connected to the I2C bus. + The device supports multiple sub-devices like LED, HWMON and WDT. + This driver provides common support for accessing the devices; + additional drivers must be enabled in order to use the + functionality of the BMC device. + + This driver can also be built as a module. If so the module + will be called menf21bmc. + config EZX_PCAP bool "Motorola EZXPCAP Support" depends on SPI_MASTER
drivers/mfd/Makefile +1 -0
@@ -169,6 +169,7 @@ obj-$(CONFIG_MFD_AS3711) += as3711.o obj-$(CONFIG_MFD_AS3722) += as3722.o obj-$(CONFIG_MFD_STW481X) += stw481x.o obj-$(CONFIG_MFD_IPAQ_MICRO) += ipaq-micro.o +obj-$(CONFIG_MFD_MENF21BMC) += menf21bmc.o intel-soc-pmic-objs := intel_soc_pmic_core.o intel_soc_pmic_crc.o obj-$(CONFIG_INTEL_SOC_PMIC) += intel-soc-pmic.o
drivers/mfd/menf21bmc.c new file +132 -0
132 lines not on this page · raw message
Signature · 1 line
2.0.4
Re: [PATCH v6 1/4] drivers/mfd/menf21bmc: introduce MEN 14F021P00 BMC MFD Core driver
T24gV2VkLCAyNyBBdWcgMjAxNCwgQW5kcmVhcyBXZXJuZXIgd3JvdGU6Cgo+IFRoZSBNRU4gMTRG MDIxUDAwIEJvYXJkIE1hbmFnZW1lbnQgQ29udHJvbGxlciBwcm92aWRlcyBhbgo+IEkyQyBpbnRl cmZhY2UgdG8gdGhlIGhvc3QgdG8gYWNjZXNzIHRoZSBmZWF0dXJlIGltcGxlbWVudGVkIGluIHRo ZSBCTUMuCj4gVGhlIEJNQyBpcyBhIFBJQyBNaWNyb250cm9sbGVyIGFzc2VtYmxlZCBvbiBDUENJ IENhcmQgZnJvbSBNRU4gTWlrcm9lbGVrdHJvbmlrCj4gYW5kIG9uIGEgZmV3IEJveC9EaXNwbGF5 IENvbXB1dGVyLgo+IAo+IEFkZGVkIE1GRCBDb3JlIGRyaXZlciwgc3VwcG9ydGluZyB0aGUgSTJD IGNvbW11bmljYXRpb24gdG8gdGhlIGRldmljZS4KPiAKPiBUaGUgTUZEIGRyaXZlciBjdXJyZW50 bHkgc3VwcG9ydHMgdGhlIGZvbGxvd2luZyBmZWF0dXJlczoKPiAgCS0gV2F0Y2hkb2cKPiAgCS0g TEVEcwo+IAktIEh3bW9uICh2b2x0YWdlIG1vbml0b3JpbmcpCj4gCj4gU2lnbmVkLW9mZi1ieTog QW5kcmVhcyBXZXJuZXIgPGFuZHJlYXMud2VybmVyQG1lbi5kZT4KPiAtLS0KPiAgZHJpdmVycy9t ZmQvS2NvbmZpZyAgICAgfCAgMTUgKysrKysrCj4gIGRyaXZlcnMvbWZkL01ha2VmaWxlICAgIHwg ICAxICsKPiAgZHJpdmVycy9tZmQvbWVuZjIxYm1jLmMgfCAxMzIgKysrKysrKysrKysrKysrKysr KysrKysrKysrKysrKysrKysrKysrKysrKysrKysrCj4gIDMgZmlsZXMgY2hhbmdlZCwgMTQ4IGlu c2VydGlvbnMoKykKPiAgY3JlYXRlIG1vZGUgMTAwNjQ0IGRyaXZlcnMvbWZkL21lbmYyMWJtYy5j CgpJJ2QgbGlrZSB0byB0YWtlIHRoaXMgc2V0IHRocm91Z2ggdGhlIE1GRCB0cmVlLCBidXQgZm9y IG5vdzoKCkFja2VkLWJ5OiBMZWUgSm9uZXMgPGxlZS5qb25lc0BsaW5hcm8ub3JnPgoKLS0gCkxl ZSBKb25lcwpMaW5hcm8gU1RNaWNyb2VsZWN0cm9uaWNzIExhbmRpbmcgVGVhbSBMZWFkCkxpbmFy by5vcmcg4pSCIE9wZW4gc291cmNlIHNvZnR3YXJlIGZvciBBUk0gU29DcwpGb2xsb3cgTGluYXJv OiBGYWNlYm9vayB8IFR3aXR0ZXIgfCBCbG9nCgpfX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fXwpsbS1zZW5zb3JzIG1haWxpbmcgbGlzdApsbS1zZW5zb3JzQGxt LXNlbnNvcnMub3JnCmh0dHA6Ly9saXN0cy5sbS1zZW5zb3JzLm9yZy9tYWlsbWFuL2xpc3RpbmZv L2xtLXNlbnNvcnM
Andreas Werner
maintainerPATCH v6 2/4 drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
In reply to Andreas WernerAdded driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.
--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+) create mode 100644 drivers/watchdog/menf21bmc_wdt.c
drivers/watchdog/Kconfig +10 -0
@@ -95,6 +95,16 @@ config GPIO_WATCHDOG If you say yes here you get support for watchdog device controlled through GPIO-line. +config MENF21BMC_WATCHDOG + tristate "MEN 14F021P00 BMC Watchdog" + depends on MFD_MENF21BMC + select WATCHDOG_CORE + help + Say Y here to include support for the MEN 14F021P00 BMC Watchdog. + + This driver can also be built as a module. If so the module + will be called menf21bmc_wdt. + config WM831X_WATCHDOG tristate "WM831x watchdog" depends on MFD_WM831X
drivers/watchdog/Makefile +1 -0
@@ -178,3 +178,4 @@ obj-$(CONFIG_WM831X_WATCHDOG) += wm831x_wdt.o obj-$(CONFIG_WM8350_WATCHDOG) += wm8350_wdt.o obj-$(CONFIG_MAX63XX_WATCHDOG) += max63xx_wdt.o obj-$(CONFIG_SOFT_WATCHDOG) += softdog.o +obj-$(CONFIG_MENF21BMC_WATCHDOG) += menf21bmc_wdt.o
drivers/watchdog/menf21bmc_wdt.c new file +203 -0
203 lines not on this page · raw message
Signature · 1 line
2.0.4
Re: [PATCH v6 2/4] drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
Wim,
We're still waiting on your Ack?
Quoted 250 lines
Added driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.Signed-off-by Andreas Werner <[email protected]>--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+) create mode 100644 drivers/watchdog/menf21bmc_wdt.cdrivers/watchdog/Kconfig +10
-0@@ -95,6 +95,16 @@ config GPIO_WATCHDOG If you say yes here you get support for watchdog device controlled through GPIO-line. +config MENF21BMC_WATCHDOG + tristate "MEN 14F021P00 BMC Watchdog" + depends on MFD_MENF21BMC + select WATCHDOG_CORE + help + Say Y here to include support for the MEN 14F021P00 BMC Watchdog. + + This driver can also be built as a module. If so the module + will be called menf21bmc_wdt. + config WM831X_WATCHDOG tristate "WM831x watchdog" depends on MFD_WM831Xdrivers/watchdog/Makefile +1
-0@@ -178,3 +178,4 @@ obj-$(CONFIG_WM831X_WATCHDOG) += wm831x_wdt.o obj-$(CONFIG_WM8350_WATCHDOG) += wm8350_wdt.o obj-$(CONFIG_MAX63XX_WATCHDOG) += max63xx_wdt.o obj-$(CONFIG_SOFT_WATCHDOG) += softdog.o +obj-$(CONFIG_MENF21BMC_WATCHDOG) += menf21bmc_wdt.odrivers/watchdog/menf21bmc_wdt.c new file +203
-0@@ -0,0 +1,203 @@ +/* +* MEN 14F021P00 Board Management Controller (BMC) Watchdog Driver. +* +* Copyright (C) 2014 MEN Mikro Elektronik Nuernberg GmbH +* +* This program is free software; you can redistribute it and/or modify it +* under the terms of the GNU General Public License as published by the +* Free Software Foundation; either version 2 of the License, or (at your +* option) any later version. +*/ + +#include <linux/kernel.h> +#include <linux/device.h> +#include <linux/module.h> +#include <linux/watchdog.h> +#include <linux/platform_device.h> +#include <linux/i2c.h> + +#define DEVNAME "menf21bmc_wdt" + +#define BMC_CMD_WD_ON 0x11 +#define BMC_CMD_WD_OFF 0x12 +#define BMC_CMD_WD_TRIG 0x13 +#define BMC_CMD_WD_TIME 0x14 +#define BMC_CMD_WD_STATE 0x17 +#define BMC_WD_OFF_VAL 0x69 +#define BMC_CMD_RST_RSN 0x92 + +#define BMC_WD_TIMEOUT_MIN 1/* in sec */ +#define BMC_WD_TIMEOUT_MAX 6553/* in sec */ + +static bool nowayout =WATCHDOG_NOWAYOUT ; +module_param (nowayout, bool,0 ); +MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" + __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); + +struct menf21bmc_wdt { +struct watchdog_device wdt; +struct i2c_client *i2c_client; +}; + +static int menf21bmc_wdt_set_bootstatus (struct menf21bmc_wdt *data) +{ +int rst_rsn; + + rst_rsn =i2c_smbus_read_byte_data (data->i2c_client,BMC_CMD_RST_RSN ); +if (rst_rsn <0 ) +return rst_rsn; + +if (rst_rsn ==0x02 ) + data->wdt.bootstatus |=WDIOF_CARDRESET ; +else if (rst_rsn ==0x05 ) + data->wdt.bootstatus |=WDIOF_EXTERN1 ; +else if (rst_rsn ==0x06 ) + data->wdt.bootstatus |=WDIOF_EXTERN2 ; +else if (rst_rsn ==0x0A ) + data->wdt.bootstatus |=WDIOF_POWERUNDER ; + +return 0 ; +} + +static int menf21bmc_wdt_start (struct watchdog_device *wdt) +{ +struct menf21bmc_wdt *drv_data =watchdog_get_drvdata (wdt); + +return i2c_smbus_write_byte (drv_data->i2c_client,BMC_CMD_WD_ON ); +} + +static int menf21bmc_wdt_stop (struct watchdog_device *wdt) +{ +struct menf21bmc_wdt *drv_data =watchdog_get_drvdata (wdt); + +return i2c_smbus_write_byte_data (drv_data->i2c_client, +BMC_CMD_WD_OFF ,BMC_WD_OFF_VAL ); +} + +static int +menf21bmc_wdt_settimeout (struct watchdog_device *wdt,unsigned int timeout) +{ +int ret; +struct menf21bmc_wdt *drv_data =watchdog_get_drvdata (wdt); + +/* +* BMC Watchdog does have a resolution of 100ms. +* Watchdog API defines the timeout in seconds, so we have to +* multiply the value. +*/ + ret =i2c_smbus_write_word_data (drv_data->i2c_client, +BMC_CMD_WD_TIME , timeout *10 ); +if (ret <0 ) +return ret; + + wdt->timeout = timeout; + +return 0 ; +} + +static int menf21bmc_wdt_ping (struct watchdog_device *wdt) +{ +struct menf21bmc_wdt *drv_data =watchdog_get_drvdata (wdt); + +return i2c_smbus_write_byte (drv_data->i2c_client,BMC_CMD_WD_TRIG ); +} + +static const struct watchdog_info menf21bmc_wdt_info = { + .options =WDIOF_SETTIMEOUT |WDIOF_KEEPALIVEPING , + .identity =DEVNAME , +}; + +static const struct watchdog_ops menf21bmc_wdt_ops = { + .owner =THIS_MODULE , + .start = menf21bmc_wdt_start, + .stop = menf21bmc_wdt_stop, + .ping = menf21bmc_wdt_ping, + .set_timeout = menf21bmc_wdt_settimeout, +}; + +static int menf21bmc_wdt_probe (struct platform_device *pdev) +{ +int ret, bmc_timeout; +struct menf21bmc_wdt *drv_data; +struct i2c_client *i2c_client =to_i2c_client (pdev->dev.parent); + + drv_data =devm_kzalloc (&pdev->dev, +sizeof (struct menf21bmc_wdt ),GFP_KERNEL ); +if (!drv_data) +return -ENOMEM ; + + drv_data->wdt.ops = &menf21bmc_wdt_ops; + drv_data->wdt.info = &menf21bmc_wdt_info; + drv_data->wdt.min_timeout =BMC_WD_TIMEOUT_MIN ; + drv_data->wdt.max_timeout =BMC_WD_TIMEOUT_MAX ; + drv_data->i2c_client = i2c_client; + +/* +* Get the current wdt timeout value from the BMC because +* the BMC will save the value set before if the system restarts. +*/ + bmc_timeout =i2c_smbus_read_word_data (drv_data->i2c_client, +BMC_CMD_WD_TIME ); +if (bmc_timeout <0 ) { +dev_err (&pdev->dev,"failed to get current WDT timeout\n" ); +return bmc_timeout; + } + +watchdog_init_timeout (&drv_data->wdt, bmc_timeout /10 , &pdev->dev); +watchdog_set_nowayout (&drv_data->wdt, nowayout); +watchdog_set_drvdata (&drv_data->wdt, drv_data); +platform_set_drvdata (pdev, drv_data); + + ret =menf21bmc_wdt_set_bootstatus (drv_data); +if (ret <0 ) { +dev_err (&pdev->dev,"failed to set Watchdog bootstatus\n" ); +return ret; + } + + ret =watchdog_register_device (&drv_data->wdt); +if (ret) { +dev_err (&pdev->dev,"failed to register Watchdog device\n" ); +return ret; + } + +dev_info (&pdev->dev,"MEN 14F021P00 BMC Watchdog device enabled\n" ); + +return 0 ; +} + +static int menf21bmc_wdt_remove (struct platform_device *pdev) +{ +struct menf21bmc_wdt *drv_data =platform_get_drvdata (pdev); + +dev_warn (&pdev->dev, +"Unregister MEN 14F021P00 BMC Watchdog device, board may reset\n" ); + +watchdog_unregister_device (&drv_data->wdt); + +return 0 ; +} + +static void menf21bmc_wdt_shutdown (struct platform_device *pdev) +{ +struct menf21bmc_wdt *drv_data =platform_get_drvdata (pdev); + +i2c_smbus_write_word_data (drv_data->i2c_client, +BMC_CMD_WD_OFF ,BMC_WD_OFF_VAL ); +} + +static struct platform_driver menf21bmc_wdt = { + .driver = { + .owner =THIS_MODULE , + .name =DEVNAME , + }, + .probe = menf21bmc_wdt_probe, + .remove = menf21bmc_wdt_remove, + .shutdown = menf21bmc_wdt_shutdown, +}; + +module_platform_driver (menf21bmc_wdt); + +MODULE_DESCRIPTION ("MEN 14F021P00 BMC Watchdog driver" ); +MODULE_AUTHOR ("Andreas Werner <[email protected]>" ); +MODULE_LICENSE ("GPL v2" ); +MODULE_ALIAS ("platform:menf21bmc_wdt" );
Signature · 9 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog _______________________________________________ lm-sensors mailing list [email protected] http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Re: [PATCH v6 2/4] drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
In reply to Andreas WernerQuoted 10 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.Signed-off-by Andreas Werner <[email protected]>--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+) create mode 100644 drivers/watchdog/menf21bmc_wdt.c
I see no reason to keep this dragging on. I'm going to apply this along with the remainder of the set and send a pull-request to all the other Maintainers. This branch is currently under test.
Any fix-ups for review comments can go in subsequently.
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Re: [PATCH v6 2/4] drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
Quoted 13 lines · Lee Jones
Quoted 10 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.Signed-off-by Andreas Werner <[email protected]>--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+)create mode 100644
drivers/watchdog/menf21bmc_wdt.c
Quoted 6 lines
I see no reason to keep this dragging on. I'm going to apply this along with the remainder of the set and send a pull-request to all the other Maintainers. This branch is currently under test.
Any fix-ups for review comments can go in subsequently.
Tend to agree. I thought I sent it before, but in case I didn't
[ for the watchdog driver ]
Guenter
Re: [PATCH v6 2/4] drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
Quoted 18 lines · Guenter Roeck
Quoted 17 lines · Lee Jones
Quoted 10 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.Signed-off-by Andreas Werner <[email protected]>--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+) create mode 100644 drivers/watchdog/menf21bmc_wdt.cI see no reason to keep this dragging on. I'm going to apply this along with the remainder of the set and send a pull-request to all the other Maintainers. This branch is currently under test.
Quoted 7 lines
Quoted 2 lines
Any fix-ups for review comments can go in subsequently.
Tend to agree. I thought I sent it before, but in case I didn't
Reviewed-by Guenter Roeck <[email protected]>[ for the watchdog driver ]
Sorry Guenter, the branch is tested, tagged and pushed.
Will be sending a pull-request shortly.
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Re: [PATCH v6 2/4] drivers/watchdog/menf21bmc_wdt: introduce MEN 14F021P00 BMC Watchdog driver
Quoted 23 lines · Lee Jones
Quoted 22 lines · Guenter Roeck
Quoted 13 lines · Lee Jones
Quoted 10 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Watchdog.
The BMC is a Board Management Controller including watchdog functionality.Signed-off-by Andreas Werner <[email protected]>--- drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 214 insertions(+) create mode 100644 drivers/watchdog/menf21bmc_wdt.cQuoted 6 lines
I see no reason to keep this dragging on. I'm going to apply this along with the remainder of the set and send a pull-request to all the other Maintainers. This branch is currently under test.
Any fix-ups for review comments can go in subsequently.
Tend to agree. I thought I sent it before, but in case I didn't
Quoted 7 lines
Quoted 3 lines
Reviewed-by Guenter Roeck <[email protected]>[ for the watchdog driver ]
Sorry Guenter, the branch is tested, tagged and pushed.
Will be sending a pull-request shortly.
Ah, screw it, I'll re-tag and push with your RB.
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Andreas Werner
maintainerPATCH v6 3/4 drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver
In reply to Andreas WernerAdded driver to support the 14F021P00 BMC LEDs.
The BMC is a Board Management Controller including four LEDs which can be switched on and off.
--- drivers/leds/Kconfig | 9 +++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 141 insertions(+) create mode 100644 drivers/leds/leds-menf21bmc.c
drivers/leds/Kconfig +9 -0
@@ -458,6 +458,15 @@ config LEDS_OT200 This option enables support for the LEDs on the Bachmann OT200. Say Y to enable LEDs on the Bachmann OT200. +config LEDS_MENF21BMC + tristate "LED support for the MEN 14F021P00 BMC" + depends on LEDS_CLASS && MFD_MENF21BMC + help + Say Y here to include support for the MEN 14F021P00 BMC LEDs. + + This driver can also be built as a module. If so the module + will be called leds-menf21bmc. + comment "LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)" config LEDS_BLINKM
drivers/leds/Makefile +1 -0
@@ -53,6 +53,7 @@ obj-$(CONFIG_LEDS_MAX8997) += leds-max8997.o obj-$(CONFIG_LEDS_LM355x) += leds-lm355x.o obj-$(CONFIG_LEDS_BLINKM) += leds-blinkm.o obj-$(CONFIG_LEDS_VERSATILE) += leds-versatile.o +obj-$(CONFIG_LEDS_MENF21BMC) += leds-menf21bmc.o # LED SPI Drivers obj-$(CONFIG_LEDS_DAC124S085) += leds-dac124s085.o
drivers/leds/leds-menf21bmc.c new file +131 -0
131 lines not on this page · raw message
Signature · 1 line
2.0.4
Re: [PATCH v6 3/4] drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver
Quoted 4 lines · Andreas Werner
Added driver to support the 14F021P00 BMC LEDs.
The BMC is a Board Management Controller including four LEDs which can be switched on and off.
Please go ahead with my Ack
Lee, will you merge this through your tree? I think we do that in one shot is better.
Thanks,
-Bryan
Quoted 180 lines
Signed-off-by Andreas Werner <[email protected]>--- drivers/leds/Kconfig | 9 +++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 141 insertions(+) create mode 100644 drivers/leds/leds-menf21bmc.cdrivers/leds/Kconfig +9
-0@@ -458,6 +458,15 @@ config LEDS_OT200 This option enables support for the LEDs on the Bachmann OT200. Say Y to enable LEDs on the Bachmann OT200. +config LEDS_MENF21BMC + tristate "LED support for the MEN 14F021P00 BMC" + depends on LEDS_CLASS && MFD_MENF21BMC + help + Say Y here to include support for the MEN 14F021P00 BMC LEDs. + + This driver can also be built as a module. If so the module + will be called leds-menf21bmc. + comment "LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)" config LEDS_BLINKMdrivers/leds/Makefile +1
-0@@ -53,6 +53,7 @@ obj-$(CONFIG_LEDS_MAX8997) += leds-max8997.o obj-$(CONFIG_LEDS_LM355x) += leds-lm355x.o obj-$(CONFIG_LEDS_BLINKM) += leds-blinkm.o obj-$(CONFIG_LEDS_VERSATILE) += leds-versatile.o +obj-$(CONFIG_LEDS_MENF21BMC) += leds-menf21bmc.o # LED SPI Drivers obj-$(CONFIG_LEDS_DAC124S085) += leds-dac124s085.odrivers/leds/leds-menf21bmc.c new file +131
-1@@ -0,0 +1,131 @@ +/* +* MEN 14F021P00 Board Management Controller (BMC) LEDs Driver. +* +* This is the core LED driver of the MEN 14F021P00 BMC. +* There are four LEDs available which can be switched on and off. +* STATUS LED, HOT SWAP LED, USER LED 1, USER LED 2 +* +* Copyright (C) 2014 MEN Mikro Elektronik Nuernberg GmbH +* +* This program is free software; you can redistribute it and/or modify it +* under the terms of the GNU General Public License as published by the +* Free Software Foundation; either version 2 of the License, or (at your +* option) any later version. +*/ + +#include <linux/module.h> +#include <linux/kernel.h> +#include <linux/platform_device.h> +#include <linux/leds.h> +#include <linux/i2c.h> + +#define BMC_CMD_LED_GET_SET 0xA0 +#define BMC_BIT_LED_STATUS BIT(0) +#define BMC_BIT_LED_HOTSWAP BIT(1) +#define BMC_BIT_LED_USER1 BIT(2) +#define BMC_BIT_LED_USER2 BIT(3) + +struct menf21bmc_led { +struct led_classdev cdev; +u8 led_bit; +const char *name; +struct i2c_client *i2c_client; +}; + +static struct menf21bmc_led leds[] = { + { + .name ="menf21bmc:led_status" , + .led_bit =BMC_BIT_LED_STATUS , + }, + { + .name ="menf21bmc:led_hotswap" , + .led_bit =BMC_BIT_LED_HOTSWAP , + }, + { + .name ="menf21bmc:led_user1" , + .led_bit =BMC_BIT_LED_USER1 , + }, + { + .name ="menf21bmc:led_user2" , + .led_bit =BMC_BIT_LED_USER2 , + } +}; + +static DEFINE_MUTEX (led_lock); + +static void +menf21bmc_led_set (struct led_classdev *led_cdev,enum led_brightness value) +{ +int led_val; +struct menf21bmc_led *led =container_of (led_cdev, + struct menf21bmc_led, cdev); + +mutex_lock (&led_lock); + led_val =i2c_smbus_read_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET ); +if (led_val <0 ) + goto err_out; + +if (value =LED_OFF ) + led_val &= ~led->led_bit; +else + led_val |= led->led_bit; + +i2c_smbus_write_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET , led_val); +err_out: +mutex_unlock (&led_lock); +} + +static int menf21bmc_led_probe (struct platform_device *pdev) +{ +int i; +int ret; +struct i2c_client *i2c_client =to_i2c_client (pdev->dev.parent); + +for (i =0 ; i <ARRAY_SIZE (leds); i++) { + leds[i].cdev.name = leds[i].name; + leds[i].cdev.brightness_set = menf21bmc_led_set; + leds[i].i2c_client = i2c_client; + ret =led_classdev_register (&pdev->dev, &leds[i].cdev); +if (ret <0 ) + goto err_free_leds; + } +dev_info (&pdev->dev,"MEN 140F21P00 BMC LED device enabled\n" ); + +return 0 ; + +err_free_leds: +dev_err (&pdev->dev,"failed to register LED device\n" ); + +for (i = i -1 ; i >=0 ; i--) +led_classdev_unregister (&leds[i].cdev); + +return ret; +} + +static int menf21bmc_led_remove (struct platform_device *pdev) +{ +int i; + +for (i =0 ; i <ARRAY_SIZE (leds); i++) +led_classdev_unregister (&leds[i].cdev); + +return 0 ; +} + +static struct platform_driver menf21bmc_led = { + .probe = menf21bmc_led_probe, + .remove = menf21bmc_led_remove, + .driver = { + .name ="menf21bmc_led" , + .owner =THIS_MODULE , + }, +}; + +module_platform_driver (menf21bmc_led); + +MODULE_AUTHOR ("Andreas Werner <[email protected]>" ); +MODULE_DESCRIPTION ("MEN 14F021P00 BMC led driver" ); +MODULE_LICENSE ("GPL v2" ); +MODULE_ALIAS ("platform:menf21bmc_led" ); --2.0.4
Quoted 4 lines
--
To unsubscribe from this list: send the line "unsubscribe linux-leds" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Re: [PATCH v6 3/4] drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver
T24gVGh1LCAyOCBBdWcgMjAxNCwgQnJ5YW4gV3Ugd3JvdGU6Cgo+IE9uIFdlZCwgQX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F9MRURfVVNFUjEsCj4gPiArICAgICAgIH0sCj4g PiArICAgICAgIHsKPiA+ICsgICAgICAgICAgICAgICAubmFtZSA9ICJtZW5mMjFibWM6bGVkX3Vz ZXIyIiwKPiA+ICsgICAgICAgICAgICAgICAubGVkX2JpdCA9IEJNQ19CSVRfTEVEX1VTRVIyLAo+ ID4gKyAgICAgICB9Cj4gPiArfTsKPiA+ICsKPiA+ICtzdGF0aWMgREVGSU5FX01VVEVYKGxlZF9s b2NrKTsKPiA+ICsKPiA+ICtzdGF0aWMgdm9pZAo+ID4gK21lbmYyMWJtY19sZWRfc2V0KHN0cnVj dCBsZWRfY2xhc3NkZXYgKmxlZF9jZGV2LCBlbnVtIGxlZF9icmlnaHRuZXNzIHZhbHVlKQo+ID4g K3sKPiA+ICsgICAgICAgaW50IGxlZF92YWw7Cj4gPiArICAgICAgIHN0cnVjdCBtZW5mMjFibWNf bGVkICpsZWQgPSBjb250YWluZXJfb2YobGVkX2NkZXYsCj4gPiArICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgc3RydWN0IG1lbmYyMWJtY19sZWQsIGNkZXYpOwo+ID4gKwo+ ID4gKyAgICAgICBtdXRleF9sb2NrKCZsZWRfbG9jayk7Cj4gPiArICAgICAgIGxlZF92YWwgPSBp MmNfc21idXNfcmVhZF9ieXRlX2RhdGEobGVkLT5pMmNfY2xpZW50LAo+ID4gKyAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEJNQ19DTURfTEVEX0dFVF9TRVQpOwo+ID4g KyAgICAgICBpZiAobGVkX3ZhbCA8IDApCj4gPiArICAgICAgICAgICAgICAgZ290byBlcnJfb3V0 Owo+ID4gKwo+ID4gKyAgICAgICBpZiAodmFsdWUgPT0gTEVEX09GRikKPiA+ICsgICAgICAgICAg ICAgICBsZWRfdmFsICY9IH5sZWQtPmxlZF9iaXQ7Cj4gPiArICAgICAgIGVsc2UKPiA+ICsgICAg ICAgICAgICAgICBsZWRf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iA+ICsgICAgICAgICAgICAgICAub3duZXIgICAgICAgICAgPSBUSElT X01PRFVMRSwKPiA+ICsgICAgICAgfSwKPiA+ICt9Owo+ID4gKwo+ID4gK21vZHVsZV9wbGF0Zm9y bV9kcml2ZXIobWVuZjIxYm1jX2xlZCk7Cj4gPiArCj4gPiArTU9EVUxFX0FVVEhPUigiQW5kcmVh cyBXZXJuZXIgPGFuZHJlYXMud2VybmVyQG1lbi5kZT4iKTsKPiA+ICtNT0RVTEVfREVTQ1JJUFRJ T04oIk1FTiAxNEYwMjFQMDAgQk1DIGxlZCBkcml2ZXIiKTsKPiA+ICtNT0RVTEVfTElDRU5TRSgi R1BMIHYyIik7Cj4gPiArTU9EVUxFX0FMSUFTKCJwbGF0Zm9ybTptZW5mMjFibWNfbGVkIik7Cj4g PgoKLS0gCkxlZSBKb25lcwpMaW5hcm8gU1RNaWNyb2VsZWN0cm9uaWNzIExhbmRpbmcgVGVhbSBM ZWFkCkxpbmFyby5vcmcg4pSCIE9wZW4gc291cmNlIHNvZnR3YXJlIGZvciBBUk0gU29DcwpGb2xs b3cgTGluYXJvOiBGYWNlYm9vayB8IFR3aXR0ZXIgfCBCbG9nCgpfX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fXwpsbS1zZW5zb3JzIG1haWxpbmcgbGlzdApsbS1z ZW5zb3JzQGxtLXNlbnNvcnMub3JnCmh0dHA6Ly9saXN0cy5sbS1zZW5zb3JzLm9yZy9tYWlsbWFu L2xpc3RpbmZvL2xtLXNlbnNvcnM
Andreas Werner
maintainerRe: [PATCH v6 3/4] drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver
Quoted 8 lines · Lee Jones
Quoted 6 lines · Bryan Wu
Quoted 4 lines · Andreas Werner
Added driver to support the 14F021P00 BMC LEDs.
The BMC is a Board Management Controller including four LEDs which can be switched on and off.
Quoted 8 lines
Quoted 5 lines
Please go ahead with my Ack
Acked-by Bryan Wu <[email protected]>Lee, will you merge this through your tree? I think we do that in one shot is better.
Yes, that's fine. Pull-request to follow.
Thanks to all for review.
Who of you does the Watchdog part? Is it the part of Wim to Ack the patch if everythings is right or Guenther?
I ask because if everything is ok all the patches can go in completly that would be nice.
Regards
Andy
Quoted 184 lines
Quoted 178 lines
Quoted 178 lines
Signed-off-by Andreas Werner <[email protected]>--- drivers/leds/Kconfig | 9 +++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 141 insertions(+) create mode 100644 drivers/leds/leds-menf21bmc.cdrivers/leds/Kconfig +9
-0@@ -458,6 +458,15 @@ config LEDS_OT200 This option enables support for the LEDs on the Bachmann OT200. Say Y to enable LEDs on the Bachmann OT200. +config LEDS_MENF21BMC + tristate "LED support for the MEN 14F021P00 BMC" + depends on LEDS_CLASS && MFD_MENF21BMC + help + Say Y here to include support for the MEN 14F021P00 BMC LEDs. + + This driver can also be built as a module. If so the module + will be called leds-menf21bmc. + comment "LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)" config LEDS_BLINKMdrivers/leds/Makefile +1
-0@@ -53,6 +53,7 @@ obj-$(CONFIG_LEDS_MAX8997) += leds-max8997.o obj-$(CONFIG_LEDS_LM355x) += leds-lm355x.o obj-$(CONFIG_LEDS_BLINKM) += leds-blinkm.o obj-$(CONFIG_LEDS_VERSATILE) += leds-versatile.o +obj-$(CONFIG_LEDS_MENF21BMC) += leds-menf21bmc.o # LED SPI Drivers obj-$(CONFIG_LEDS_DAC124S085) += leds-dac124s085.odrivers/leds/leds-menf21bmc.c new file +131
-0@@ -0,0 +1,131 @@ +/* +* MEN 14F021P00 Board Management Controller (BMC) LEDs Driver. +* +* This is the core LED driver of the MEN 14F021P00 BMC. +* There are four LEDs available which can be switched on and off. +* STATUS LED, HOT SWAP LED, USER LED 1, USER LED 2 +* +* Copyright (C) 2014 MEN Mikro Elektronik Nuernberg GmbH +* +* This program is free software; you can redistribute it and/or modify it +* under the terms of the GNU General Public License as published by the +* Free Software Foundation; either version 2 of the License, or (at your +* option) any later version. +*/ + +#include <linux/module.h> +#include <linux/kernel.h> +#include <linux/platform_device.h> +#include <linux/leds.h> +#include <linux/i2c.h> + +#define BMC_CMD_LED_GET_SET 0xA0 +#define BMC_BIT_LED_STATUS BIT(0) +#define BMC_BIT_LED_HOTSWAP BIT(1) +#define BMC_BIT_LED_USER1 BIT(2) +#define BMC_BIT_LED_USER2 BIT(3) + +struct menf21bmc_led { +struct led_classdev cdev; +u8 led_bit; +const char *name; +struct i2c_client *i2c_client; +}; + +static struct menf21bmc_led leds[] = { + { + .name ="menf21bmc:led_status" , + .led_bit =BMC_BIT_LED_STATUS , + }, + { + .name ="menf21bmc:led_hotswap" , + .led_bit =BMC_BIT_LED_HOTSWAP , + }, + { + .name ="menf21bmc:led_user1" , + .led_bit =BMC_BIT_LED_USER1 , + }, + { + .name ="menf21bmc:led_user2" , + .led_bit =BMC_BIT_LED_USER2 , + } +}; + +static DEFINE_MUTEX (led_lock); + +static void +menf21bmc_led_set (struct led_classdev *led_cdev,enum led_brightness value) +{ +int led_val; +struct menf21bmc_led *led =container_of (led_cdev, + struct menf21bmc_led, cdev); + +mutex_lock (&led_lock); + led_val =i2c_smbus_read_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET ); +if (led_val <0 ) + goto err_out; + +if (value ==LED_OFF ) + led_val &= ~led->led_bit; +else + led_val |= led->led_bit; + +i2c_smbus_write_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET , led_val); +err_out: +mutex_unlock (&led_lock); +} + +static int menf21bmc_led_probe (struct platform_device *pdev) +{ +int i; +int ret; +struct i2c_client *i2c_client =to_i2c_client (pdev->dev.parent); + +for (i =0 ; i <ARRAY_SIZE (leds); i++) { + leds[i].cdev.name = leds[i].name; + leds[i].cdev.brightness_set = menf21bmc_led_set; + leds[i].i2c_client = i2c_client; + ret =led_classdev_register (&pdev->dev, &leds[i].cdev); +if (ret <0 ) + goto err_free_leds; + } +dev_info (&pdev->dev,"MEN 140F21P00 BMC LED device enabled\n" ); + +return 0 ; + +err_free_leds: +dev_err (&pdev->dev,"failed to register LED device\n" ); + +for (i = i -1 ; i >=0 ; i--) +led_classdev_unregister (&leds[i].cdev); + +return ret; +} + +static int menf21bmc_led_remove (struct platform_device *pdev) +{ +int i; + +for (i =0 ; i <ARRAY_SIZE (leds); i++) +led_classdev_unregister (&leds[i].cdev); + +return 0 ; +} + +static struct platform_driver menf21bmc_led = { + .probe = menf21bmc_led_probe, + .remove = menf21bmc_led_remove, + .driver = { + .name ="menf21bmc_led" , + .owner =THIS_MODULE , + }, +}; + +module_platform_driver (menf21bmc_led); + +MODULE_AUTHOR ("Andreas Werner <[email protected]>" ); +MODULE_DESCRIPTION ("MEN 14F021P00 BMC led driver" ); +MODULE_LICENSE ("GPL v2" ); +MODULE_ALIAS ("platform:menf21bmc_led" );Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Re: [PATCH v6 3/4] drivers/leds/leds-menf21bmc: introduce MEN 14F021P00 BMC LED driver
Quoted 15 lines · Andreas Werner
Quoted 14 lines · Lee Jones
Quoted 11 lines · Bryan Wu
Quoted 4 lines · Andreas Werner
Added driver to support the 14F021P00 BMC LEDs.
The BMC is a Board Management Controller including four LEDs which can be switched on and off.Please go ahead with my Ack
Acked-by Bryan Wu <[email protected]>Lee, will you merge this through your tree? I think we do that in one shot is better.
Quoted 7 lines
Quoted 2 lines
Yes, that's fine. Pull-request to follow.
Thanks to all for review.
Who of you does the Watchdog part? Is it the part of Wim to Ack the patch if everythings is right or Guenther?
Wim looks like the guy:
WATCHDOG DEVICE DRIVERS
M: Wim Van Sebroeck <[email protected]> L: [email protected] W: http://www.linux-watchdog.org/ T: git git://www.linux-watchdog.org/linux-watchdog.git S: Maintained F: Documentation/watchdog/ F: drivers/watchdog/ F: include/linux/watchdog.h F: include/uapi/linux/watchdog.h
Quoted 2 lines
I ask because if everything is ok all the patches can go in completly that would be nice.
That is the plan.
Quoted 179 lines
Quoted 179 lines
Quoted 178 lines
Quoted 178 lines
Signed-off-by Andreas Werner <[email protected]>--- drivers/leds/Kconfig | 9 +++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 141 insertions(+) create mode 100644 drivers/leds/leds-menf21bmc.cdrivers/leds/Kconfig +9
-0@@ -458,6 +458,15 @@ config LEDS_OT200 This option enables support for the LEDs on the Bachmann OT200. Say Y to enable LEDs on the Bachmann OT200. +config LEDS_MENF21BMC + tristate "LED support for the MEN 14F021P00 BMC" + depends on LEDS_CLASS && MFD_MENF21BMC + help + Say Y here to include support for the MEN 14F021P00 BMC LEDs. + + This driver can also be built as a module. If so the module + will be called leds-menf21bmc. + comment "LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)" config LEDS_BLINKMdrivers/leds/Makefile +1
-0@@ -53,6 +53,7 @@ obj-$(CONFIG_LEDS_MAX8997) += leds-max8997.o obj-$(CONFIG_LEDS_LM355x) += leds-lm355x.o obj-$(CONFIG_LEDS_BLINKM) += leds-blinkm.o obj-$(CONFIG_LEDS_VERSATILE) += leds-versatile.o +obj-$(CONFIG_LEDS_MENF21BMC) += leds-menf21bmc.o # LED SPI Drivers obj-$(CONFIG_LEDS_DAC124S085) += leds-dac124s085.odrivers/leds/leds-menf21bmc.c new file +131
-0@@ -0,0 +1,131 @@ +/* +* MEN 14F021P00 Board Management Controller (BMC) LEDs Driver. +* +* This is the core LED driver of the MEN 14F021P00 BMC. +* There are four LEDs available which can be switched on and off. +* STATUS LED, HOT SWAP LED, USER LED 1, USER LED 2 +* +* Copyright (C) 2014 MEN Mikro Elektronik Nuernberg GmbH +* +* This program is free software; you can redistribute it and/or modify it +* under the terms of the GNU General Public License as published by the +* Free Software Foundation; either version 2 of the License, or (at your +* option) any later version. +*/ + +#include <linux/module.h> +#include <linux/kernel.h> +#include <linux/platform_device.h> +#include <linux/leds.h> +#include <linux/i2c.h> + +#define BMC_CMD_LED_GET_SET 0xA0 +#define BMC_BIT_LED_STATUS BIT(0) +#define BMC_BIT_LED_HOTSWAP BIT(1) +#define BMC_BIT_LED_USER1 BIT(2) +#define BMC_BIT_LED_USER2 BIT(3) + +struct menf21bmc_led { +struct led_classdev cdev; +u8 led_bit; +const char *name; +struct i2c_client *i2c_client; +}; + +static struct menf21bmc_led leds[] = { + { + .name ="menf21bmc:led_status" , + .led_bit =BMC_BIT_LED_STATUS , + }, + { + .name ="menf21bmc:led_hotswap" , + .led_bit =BMC_BIT_LED_HOTSWAP , + }, + { + .name ="menf21bmc:led_user1" , + .led_bit =BMC_BIT_LED_USER1 , + }, + { + .name ="menf21bmc:led_user2" , + .led_bit =BMC_BIT_LED_USER2 , + } +}; + +static DEFINE_MUTEX (led_lock); + +static void +menf21bmc_led_set (struct led_classdev *led_cdev,enum led_brightness value) +{ +int led_val; +struct menf21bmc_led *led =container_of (led_cdev, + struct menf21bmc_led, cdev); + +mutex_lock (&led_lock); + led_val =i2c_smbus_read_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET ); +if (led_val <0 ) + goto err_out; + +if (value ==LED_OFF ) + led_val &= ~led->led_bit; +else + led_val |= led->led_bit; + +i2c_smbus_write_byte_data (led->i2c_client, +BMC_CMD_LED_GET_SET , led_val); +err_out: +mutex_unlock (&led_lock); +} + +static int menf21bmc_led_probe (struct platform_device *pdev) +{ +int i; +int ret; +struct i2c_client *i2c_client =to_i2c_client (pdev->dev.parent); + +for (i =0 ; i <ARRAY_SIZE (leds); i++) { + leds[i].cdev.name = leds[i].name; + leds[i].cdev.brightness_set = menf21bmc_led_set; + leds[i].i2c_client = i2c_client; + ret =led_classdev_register (&pdev->dev, &leds[i].cdev); +if (ret <0 ) + goto err_free_leds; + } +dev_info (&pdev->dev,"MEN 140F21P00 BMC LED device enabled\n" ); + +return 0 ; + +err_free_leds: +dev_err (&pdev->dev,"failed to register LED device\n" ); + +for (i = i -1 ; i >=0 ; i--) +led_classdev_unregister (&leds[i].cdev); + +return ret; +} + +static int menf21bmc_led_remove (struct platform_device *pdev) +{ +int i; + +for (i =0 ; i <ARRAY_SIZE (leds); i++) +led_classdev_unregister (&leds[i].cdev); + +return 0 ; +} + +static struct platform_driver menf21bmc_led = { + .probe = menf21bmc_led_probe, + .remove = menf21bmc_led_remove, + .driver = { + .name ="menf21bmc_led" , + .owner =THIS_MODULE , + }, +}; + +module_platform_driver (menf21bmc_led); + +MODULE_AUTHOR ("Andreas Werner <[email protected]>" ); +MODULE_DESCRIPTION ("MEN 14F021P00 BMC led driver" ); +MODULE_LICENSE ("GPL v2" ); +MODULE_ALIAS ("platform:menf21bmc_led" );
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Andreas Werner
maintainerPATCH v6 4/4 drivers/hwmon/menf21bmc_hwmon: introduce MEN14F021P00 BMC HWMON driver
In reply to Andreas WernerAdded driver to support the 14F021P00 BMC Hardware Monitoring. The BMC is a Board Management Controller including monitoring of the board voltages.
--- Documentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 291 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c
Documentation/hwmon/menf21bmc new file +50 -0
@@ -0,0 +1,50 @@ +Kernel driver menf21bmc_hwmon +============================= + +Supported chips: + * MEN 14F021P00 + Prefix: 'menf21bmc_hwmon' + Adresses scanned: - + +Author: Andreas Werner <[email protected]> + +Description +----------- + +The menf21bmc is a Board Management Controller (BMC) which provides an I2C +interface to the host to access the features implemented in the BMC. + +This driver gives access to the voltage monitoring feature of the main +voltages of the board. +The voltage sensors are connected to the ADC inputs of the BMC which is +a PIC16F917 Mikrocontroller. + +Usage Notes +----------- + +This driver is part of the MFD driver named "menf21bmc" and does +not auto-detect devices. +You will have to instantiate the MFD driver explicitly. +Please see Documentation/i2c/instantiating-devices for +details. + +Sysfs entries +------------- + +The following attributes are supported. All attributes are read only +The Limits are read once by the driver. + +in0_input +3.3V input voltage +in1_input +5.0V input voltage +in2_input +12.0V input voltage +in3_input +5V Standby input voltage +in4_input VBAT (on board battery) + +in[0-4]_min Minimum voltage limit +in[0-4]_max Maximum voltage limit + +in0_label "MON_3_3V" +in1_label "MON_5V" +in2_label "MON_12V" +in3_label "5V_STANDBY" +in4_label "VBAT"
drivers/hwmon/Kconfig +10 -0
@@ -828,6 +828,16 @@ config SENSORS_MCP3021 This driver can also be built as a module. If so, the module will be called mcp3021. +config SENSORS_MENF21BMC_HWMON + tristate "MEN 14F021P00 BMC Hardware Monitoring" + depends on MFD_MENF21BMC + help + Say Y here to include support for the MEN 14F021P00 BMC + hardware monitoring. + + This driver can also be built as a module. If so the module + will be called menf21bmc_hwmon. + config SENSORS_ADCXX tristate "National Semiconductor ADCxxxSxxx" depends on SPI_MASTER
drivers/hwmon/Makefile +1 -0
@@ -114,6 +114,7 @@ obj-$(CONFIG_SENSORS_MAX6650) += max6650.o obj-$(CONFIG_SENSORS_MAX6697) += max6697.o obj-$(CONFIG_SENSORS_MC13783_ADC)+= mc13783-adc.o obj-$(CONFIG_SENSORS_MCP3021) += mcp3021.o +obj-$(CONFIG_SENSORS_MENF21BMC_HWMON) += menf21bmc_hwmon.o obj-$(CONFIG_SENSORS_NCT6683) += nct6683.o obj-$(CONFIG_SENSORS_NCT6775) += nct6775.o obj-$(CONFIG_SENSORS_NTC_THERMISTOR) += ntc_thermistor.o
drivers/hwmon/menf21bmc_hwmon.c new file +230 -0
230 lines not on this page · raw message
Signature · 1 line
2.0.4
Re: [PATCH v6 4/4] drivers/hwmon/menf21bmc_hwmon: introduce MEN14F021P00 BMC HWMON driver
Quoted 5 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Hardware Monitoring. The BMC is a Board Management Controller including monitoring of the board voltages.
Signed-off-by Andreas Werner <[email protected]>
Looks good, though I do have one comment ...
drivers/hwmon/menf21bmc_hwmon.c line 213
Quoted 9 lines
drivers/hwmon/menf21bmc_hwmon.c new file +9
-0+ + hwmon_dev =devm_hwmon_device_register_with_groups (&pdev->dev, +"menf21bmc" , drv_data, + menf21bmc_hwmon_groups); +if (IS_ERR (hwmon_dev)) +return PTR_ERR (hwmon_dev); + +dev_info (&pdev->dev,"MEN 14F021P00 BMC hwmon device enabled" ); +
You removed the dev_info from the mfd driver but left it in the client drivers. If you'd drop it here as well, you could use 'return PTR_ERR_OR_ZERO(hwmon_dev);'. Just a suggestion, not mandatory.
Either case,
I assume this will go in through the mfd tree.
Thanks,
Guenter
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Andreas Werner
maintainerRe: [PATCH v6 4/4] drivers/hwmon/menf21bmc_hwmon: introduce MEN14F021P00 BMC HWMON driver
Quoted 22 lines · Guenter Roeck
Quoted 5 lines · Andreas Werner
Added driver to support the 14F021P00 BMC Hardware Monitoring. The BMC is a Board Management Controller including monitoring of the board voltages.
Signed-off-by Andreas Werner <[email protected]>Looks good, though I do have one comment ...
drivers/hwmon/menf21bmc_hwmon.c line 213
Quoted 9 lines
drivers/hwmon/menf21bmc_hwmon.c new file +9
-0+ + hwmon_dev =devm_hwmon_device_register_with_groups (&pdev->dev, +"menf21bmc" , drv_data, + menf21bmc_hwmon_groups); +if (IS_ERR (hwmon_dev)) +return PTR_ERR (hwmon_dev); + +dev_info (&pdev->dev,"MEN 14F021P00 BMC hwmon device enabled" ); +You removed the
dev_infofrom the mfd driver but left it in the client drivers. If you'd drop it here as well, you could use 'returnPTR_ERR_OR_ZERO(hwmon_dev);'. Just a suggestion, not mandatory.
Quoted 1 line
Either case,
It is a nice info for every slave driver which are the drivers for accessing the features in the BMC. The mfd is just the driver who will instantiate the slaves. For the mfd the most important info is if there was an error.
Anyway good idea with PTR_ERR_OR_ZERO.
Thanks for the nice review and the comments.
Regards
Andy
Quoted 7 lines
Reviewed-by Guenter Roeck <[email protected]>I assume this will go in through the mfd tree.
Thanks,
Guenter
Andreas Werner
maintainerPATCH 1/1 MAINTAINERS: Adds Andreas Werner to maintainers list for MEN F21BMC
In reply to Andreas WernerAdded maintainer for the following MEN F21BMC drivers:
- menf21bmc (MFD)
- menf21bmc_wdt (Watchdog)
- menf21bmc_hwmon (HWMON)
- leds-menf21bmc (LED)
--- MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+)
MAINTAINERS +9 -0
@@ -5938,6 +5938,15 @@ S: Supported F: drivers/mcb/ F: include/linux/mcb.h +MEN F21BMC (Board Management Controller) +M: Andreas Werner <[email protected]> +S: Supported +F: drivers/mfd/menf21bmc.c +F: drivers/watchdog/menf21bmc_wdt.c +F: drivers/leds/leds-menf21bmc.c +F: drivers/hwmon/menf21bmc_hwmon.c +F: Documentation/hwmon/menf21bmc + METAG ARCHITECTURE M: James Hogan <[email protected]> L: [email protected]
Signature · 1 line
2.0.4
Re: [PATCH] MAINTAINERS: Adds Andreas Werner to maintainers list for MEN F21BMC
Quoted 10 lines · Andreas Werner
Added maintainer for the following MEN F21BMC drivers:
- menf21bmc (MFD)
-menf21bmc_wdt(Watchdog)
-menf21bmc_hwmon(HWMON)
- leds-menf21bmc (LED)Signed-off-by Andreas Werner <[email protected]>--- MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+)
Quoted 20 lines
MAINTAINERS +9
-0@@ -5938,6 +5938,15 @@ S: Supported F: drivers/mcb/ F: include/linux/mcb.h +MEN F21BMC (Board Management Controller) +M: Andreas Werner <[email protected]> +S: Supported +F: drivers/mfd/menf21bmc.c +F: drivers/watchdog/menf21bmc_wdt.c +F: drivers/leds/leds-menf21bmc.c +F: drivers/hwmon/menf21bmc_hwmon.c +F: Documentation/hwmon/menf21bmc + METAG ARCHITECTURE M: James Hogan <[email protected]> L: [email protected]
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Andreas Werner
maintainerRe: [PATCH] MAINTAINERS: Adds Andreas Werner to maintainers list for MEN F21BMC
Quoted 8 lines · Lee Jones
Quoted 6 lines · Andreas Werner
Added maintainer for the following MEN F21BMC drivers:
- menf21bmc (MFD)
-menf21bmc_wdt(Watchdog)
-menf21bmc_hwmon(HWMON)
- leds-menf21bmc (LED)
Quoted 7 lines
Quoted 4 lines
Signed-off-by Andreas Werner <[email protected]>--- MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+)Acked-by Lee Jones <[email protected]>
Thanks.
I think we are almost complete.
Just the Watchdog needs to be Acked if everything is ok.
Regards
Andy
Quoted 26 lines
Quoted 20 lines
MAINTAINERS +9
-0@@ -5938,6 +5938,15 @@ S: Supported F: drivers/mcb/ F: include/linux/mcb.h +MEN F21BMC (Board Management Controller) +M: Andreas Werner <[email protected]> +S: Supported +F: drivers/mfd/menf21bmc.c +F: drivers/watchdog/menf21bmc_wdt.c +F: drivers/leds/leds-menf21bmc.c +F: drivers/hwmon/menf21bmc_hwmon.c +F: Documentation/hwmon/menf21bmc + METAG ARCHITECTURE M: James Hogan <[email protected]> L: [email protected]Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
[GIT PULL] Immutable branch between MFD, HWMON, LEDs and Watchdog
In reply to Andreas WernerThe following changes since commit 52addcf9d6669fa439387610bc65c92fa0980cef:
Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git tags/mfd-hwmon-leds-watchdog-v3.17
for you to fetch changes up to 25b1efbf5ff8a2475e29572065cac3d89cee24b1:
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 13:31:20 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.17
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog: menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver
Documentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Guenter, Bryan, Wim,
The following changes since commit 52addcf9d6669fa439387610bc65c92fa0980cef:
Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git tags/mfd-hwmon-leds-watchdog-v3.18
for you to fetch changes up to 964356938fcd3c0001a786f55b9f0a0fbe47656a:
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog: menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver
Documentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Guenter Roeck
maintainerQuoted 8 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
Quoted 9 lines
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18
I assume you'll push it all through mfd, correct ?
Thanks,
Guenter
Quoted 18 lines
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog:menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driverDocumentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++
Quoted 14 lines
drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.cSignature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18
Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
So in answer to your question; yes I'll be taking this, but so should each of you.
Quoted 27 lines
Quoted 27 lines
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog:menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driverDocumentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Guenter Roeck
maintainerQuoted 20 lines · Lee Jones
Quoted 18 lines · Guenter Roeck
Quoted 17 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18
Quoted 9 lines
Quoted 1 line
I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
So in answer to your question; yes I'll be taking this, but so should each of you.
No problem with me. Let's see how it goes.
Guenter
Quoted 20 lines · Lee Jones
Quoted 18 lines · Guenter Roeck
Quoted 17 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18
Quoted 9 lines
Quoted 1 line
I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I was confused, sorry.
-Bryan
Quoted 33 lines
Quoted 19 lines
Quoted 19 lines
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog:menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driverDocumentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 +Quoted 8 lines
Quoted 8 lines
drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c--
Lee Jones
Linaro STMicroelectronics Landing Team LeadLinaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Guenter Roeck
maintainerQuoted 27 lines · Bryan Wu
Quoted 26 lines · Lee Jones
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
Thanks,
Guenter
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Quoted 43 lines · Guenter Roeck
Quoted 27 lines · Bryan Wu
Quoted 26 lines · Lee Jones
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18
Quoted 8 lines
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
Great, thanks a lot. I just did the same thing for my leds tree.
-Bryan
Quoted 43 lines · Guenter Roeck
Quoted 27 lines · Bryan Wu
Quoted 26 lines · Lee Jones
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18
Quoted 7 lines
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
That's right. It's not okay to break this branch up. If it was, we would have been able to apply our respective components into our own trees from the beginning, but as there are interdependencies, breaking up the branch could have nasty consequences depending on the order in which they land in Mainline. Most likely bisectability will be broken, which is not allowed.
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Hi All,
Quoted 53 lines · Guenter Roeck
Quoted 44 lines · Bryan Wu
Quoted 27 lines · Lee Jones
Quoted 26 lines · Guenter Roeck
Quoted 12 lines · Lee Jones
Quoted 10 lines
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18Quoted 7 lines
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
Quoted 6 lines
That's right. It's not okay to break this branch up. If it was, we would have been able to apply our respective components into our own trees from the beginning, but as there are interdependencies, breaking up the branch could have nasty consequences depending on the order in which they land in Mainline. Most likely bisectability will be broken, which is not allowed.
Added to linux-watchdog-next.
Kind regards,
Wim.
Andreas Werner
maintainerQuoted 53 lines · Lee Jones
Quoted 43 lines · Guenter Roeck
Quoted 27 lines · Bryan Wu
Quoted 26 lines · Lee Jones
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18Quoted 7 lines
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
Quoted 7 lines
That's right. It's not okay to break this branch up. If it was, we would have been able to apply our respective components into our own trees from the beginning, but as there are interdependencies, breaking up the branch could have nasty consequences depending on the order in which they land in Mainline. Most likely bisectability will be broken, which is not allowed.
Hi,
please do not forget the MAINTAINERS Patch for this series. I have send it last week attached to this series.
Thanks
Regards
Andy
Quoted 5 lines
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
Quoted 62 lines · Andreas Werner
Quoted 53 lines · Lee Jones
Quoted 43 lines · Guenter Roeck
Quoted 27 lines · Bryan Wu
Quoted 26 lines · Lee Jones
Quoted 11 lines · Guenter Roeck
Quoted 10 lines · Lee Jones
Guenter, Bryan, Wim,
The following changes since commit
52addcf9d6669fa439387610bc65c92fa0980cef:Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.gittags/mfd-hwmon-leds-watchdog-v3.18Quoted 8 lines
Quoted 7 lines
for you to fetch changes up to
964356938fcd3c0001a786f55b9f0a0fbe47656a:hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18I assume you'll push it all through mfd, correct ?
The idea is for all the affected Maintainers to pull this branch in to their own trees. If you guys don't, there will be a good chance of conflict during the merge-window, which will subsequently upset Linus.
Quoted 9 lines
Quoted 3 lines
So in answer to your question; yes I'll be taking this, but so should each of you.
Thanks for this, man. What am I going to do here? Need I pull in all the patches here into my LED tree or just one LED patch? I think if you push this for Linus through MFD tree, I don't need to pull it into my tree, right?
I did
git remote add mfd
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git
git fetch --tags mfd
git merge mfd-hwmon-leds-watchdog-v3.18Quoted 7 lines
in both my hwmon-next and watchdog-next branches. Both are currently building, and already pushed into to my repository at kernel.org.
So, effectively, when I send my pull request to Linus, all patches from mfd-hwmon-leds-watchdog-v3.18 will be included, ie the entire series. The same will happen when Lee sends his pull request, and Wim, and you. I believe that is what Lee is asking for.
Quoted 7 lines
That's right. It's not okay to break this branch up. If it was, we would have been able to apply our respective components into our own trees from the beginning, but as there are interdependencies, breaking up the branch could have nasty consequences depending on the order in which they land in Mainline. Most likely bisectability will be broken, which is not allowed.
Quoted 3 lines
Hi,
please do not forget theMAINTAINERSPatch for this series. I have send it last week attached to this series.
I'll take this through the MFD tree with everyone's Ack.
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog
[GIT PULL] MFD: Immutable branch between HWMON, LEDs and Watchdog
In reply to Andreas WernerGuenter, Bryan, Wim,
The following changes since commit 52addcf9d6669fa439387610bc65c92fa0980cef:
Linux 3.17-rc2 (2014-08-25 15:36:20 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git tags/mfd-hwmon-leds-watchdog-v3.18
for you to fetch changes up to 964356938fcd3c0001a786f55b9f0a0fbe47656a:
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver (2014-09-24 15:36:33 +0100)
----------------------------------------------------------------
Immutable branch between MFD, HWMON, LEDs and Watchdog for v3.18
----------------------------------------------------------------
Andreas Werner (4):
mfd: menf21bmc: Introduce MEN 14F021P00 BMC MFD Core driver
watchdog: menf21bmc_wdt: Introduce MEN 14F021P00 BMC Watchdog driver
leds: leds-menf21bmc: Introduce MEN 14F021P00 BMC LED driver
hwmon: (menf21bmc) Introduce MEN14F021P00 BMC HWMON driver
Documentation/hwmon/menf21bmc | 50 +++++++++ drivers/hwmon/Kconfig | 10 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/menf21bmc_hwmon.c | 230 +++++++++++++++++++++++++++++++++++++++ drivers/leds/Kconfig | 9 ++ drivers/leds/Makefile | 1 + drivers/leds/leds-menf21bmc.c | 131 ++++++++++++++++++++++ drivers/mfd/Kconfig | 15 +++ drivers/mfd/Makefile | 1 + drivers/mfd/menf21bmc.c | 132 ++++++++++++++++++++++ drivers/watchdog/Kconfig | 10 ++ drivers/watchdog/Makefile | 1 + drivers/watchdog/menf21bmc_wdt.c | 203 ++++++++++++++++++++++++++++++++++ 13 files changed, 794 insertions(+) create mode 100644 Documentation/hwmon/menf21bmc create mode 100644 drivers/hwmon/menf21bmc_hwmon.c create mode 100644 drivers/leds/leds-menf21bmc.c create mode 100644 drivers/mfd/menf21bmc.c create mode 100644 drivers/watchdog/menf21bmc_wdt.c
Signature · 4 lines
Lee Jones Linaro STMicroelectronics Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog