w1: Add subsystem kernel public interface

Like other subsystems we should be able to define slave devices outside
of the w1 directory. To do this we move public facing interface
definitions to include/linux/w1.h and rename the internal definition
file to w1_internal.h.

As w1_family.h and w1_int.h contained almost entirely public
driver interface definitions we simply removed these files and
moved the remaining definitions into w1_internal.h.

With this we can now start to move slave devices out of w1/slaves and
into the subsystem based on the function they implement, again like
other drivers.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Reviewed-by: Sebastian Reichel <sre@kernel.org>
Acked-by: Evgeniy Polyakov <zbr@ioremap.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Andrew F. Davis
2017-06-05 08:52:08 -05:00
committed by Greg Kroah-Hartman
parent acb7e8f744
commit de0d6dbdbd
36 changed files with 208 additions and 260 deletions

View File

@@ -13790,6 +13790,7 @@ M: Evgeniy Polyakov <zbr@ioremap.net>
S: Maintained
F: Documentation/w1/
F: drivers/w1/
F: include/linux/w1.h
W83791D HARDWARE MONITORING DRIVER
M: Marc Hulsman <m.hulsman@tudelft.nl>

View File

@@ -28,7 +28,7 @@
#include <linux/platform_device.h>
#include <linux/power_supply.h>
#include "../../w1/w1.h"
#include <linux/w1.h>
#include "../../w1/slaves/w1_ds2760.h"
struct ds2760_device_info {

View File

@@ -21,7 +21,7 @@
#include <linux/power_supply.h>
#include <linux/idr.h>
#include "../../w1/w1.h"
#include <linux/w1.h>
#include "../../w1/slaves/w1_ds2780.h"
/* Current unit measurement in uA for a 1 milli-ohm sense resistor */

View File

@@ -19,7 +19,7 @@
#include <linux/power_supply.h>
#include <linux/idr.h>
#include "../../w1/w1.h"
#include <linux/w1.h>
#include "../../w1/slaves/w1_ds2781.h"
/* Current unit measurement in uA for a 1 milli-ohm sense resistor */

View File

@@ -25,8 +25,7 @@
#include <asm/io.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
#define DS1WM_CMD 0x00 /* R/W 4 bits command */

View File

@@ -20,8 +20,7 @@
#include <linux/delay.h>
#include <asm/delay.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
/**
* Allow the active pullup to be disabled, default is enabled.

View File

@@ -25,8 +25,7 @@
#include <linux/usb.h>
#include <linux/slab.h>
#include "../w1_int.h"
#include "../w1.h"
#include <linux/w1.h>
/* USB Standard */
/* USB Control request vendor type */

View File

@@ -34,8 +34,7 @@
#include <linux/pci_ids.h>
#include <linux/pci.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
/*
* Matrox G400 DDC registers.

View File

@@ -19,8 +19,7 @@
#include <linux/module.h>
#include <linux/platform_device.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
/*
* MXC W1 Register offsets

View File

@@ -19,8 +19,7 @@
#include <linux/pm_runtime.h>
#include <linux/of.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
#define MOD_NAME "OMAP_HDQ:"

View File

@@ -20,8 +20,7 @@
#include <linux/of.h>
#include <linux/delay.h>
#include "../w1.h"
#include "../w1_int.h"
#include <linux/w1.h>
static u8 w1_gpio_set_pullup(void *data, int delay)
{

View File

@@ -17,9 +17,9 @@
#include <linux/mutex.h>
#include <linux/power/bq27xxx_battery.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_BQ27000 0x01
#define HDQ_CMD_READ (0)
#define HDQ_CMD_WRITE (1<<7)

View File

@@ -24,8 +24,9 @@
#include <linux/string.h>
#include <linux/types.h>
#include "../w1.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_DS2405 0x05
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Maciej S. Szmigiero <mail@maciej.szmigiero.name>");

View File

@@ -17,9 +17,9 @@
#include <linux/slab.h>
#include <linux/crc16.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_DS2406 0x12
#define W1_F12_FUNC_READ_STATUS 0xAA
#define W1_F12_FUNC_WRITE_STATUS 0x55

View File

@@ -15,9 +15,9 @@
#include <linux/delay.h>
#include <linux/slab.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_DS2408 0x29
#define W1_F29_RETRIES 3

View File

@@ -16,9 +16,9 @@
#include <linux/delay.h>
#include <linux/slab.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_DS2413 0x3A
#define W1_F3A_RETRIES 3
#define W1_F3A_FUNC_PIO_ACCESS_READ 0xF5

View File

@@ -30,9 +30,9 @@
#include <linux/delay.h>
#include <linux/crc16.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_COUNTER_DS2423 0x1D
#define CRC16_VALID 0xb001
#define CRC16_INIT 0

View File

@@ -16,9 +16,9 @@
#include <linux/types.h>
#include <linux/delay.h>
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_EEPROM_DS2431 0x2D
#define W1_F2D_EEPROM_SIZE 128
#define W1_F2D_PAGE_COUNT 4

View File

@@ -22,9 +22,9 @@
#endif
#include "../w1.h"
#include "../w1_int.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_EEPROM_DS2433 0x23
#define W1_EEPROM_SIZE 512
#define W1_PAGE_COUNT 16

View File

@@ -13,8 +13,9 @@
#include <linux/types.h>
#include <linux/delay.h>
#include "../w1.h"
#include "../w1_family.h"
#include <linux/w1.h>
#define W1_FAMILY_DS2438 0x26
#define W1_DS2438_RETRIES 3

Some files were not shown because too many files have changed in this diff Show More