mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-22 14:41:27 +00:00
platform/x86: Move Mellanox platform hotplug driver to platform/mellanox
In preparation for making the hotplug driver build for different architectures, move mlxcpld-hotplug.c to platform/mellanox and the header to include/linux/platform_data as mlxreg.h to reflect the new interface changes to come. Replace references to CPLD with REG throughout the files, consistent with the new name. Signed-off-by: Vadim Pasternak <vadimp@mellanox.com> Acked-by: Andy Shevchenko <andy.shevchenko@gmail.com> [dvhart: update copyright, rewrite commit message] Signed-off-by: Darren Hart (VMware) <dvhart@infradead.org>
This commit is contained in:
parent
d6fa7588fd
commit
1f976f6978
10 changed files with 170 additions and 146 deletions
|
@ -1,7 +1,6 @@
|
|||
/*
|
||||
* include/linux/platform_data/mlxcpld-hotplug.h
|
||||
* Copyright (c) 2016 Mellanox Technologies. All rights reserved.
|
||||
* Copyright (c) 2016 Vadim Pasternak <vadimp@mellanox.com>
|
||||
* Copyright (c) 2017 Mellanox Technologies. All rights reserved.
|
||||
* Copyright (c) 2017 Vadim Pasternak <vadimp@mellanox.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
|
@ -32,11 +31,11 @@
|
|||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef __LINUX_PLATFORM_DATA_MLXCPLD_HOTPLUG_H
|
||||
#define __LINUX_PLATFORM_DATA_MLXCPLD_HOTPLUG_H
|
||||
#ifndef __LINUX_PLATFORM_DATA_MLXREG_H
|
||||
#define __LINUX_PLATFORM_DATA_MLXREG_H
|
||||
|
||||
/**
|
||||
* struct mlxcpld_hotplug_device - I2C device data:
|
||||
* struct mlxreg_hotplug_device - I2C device data:
|
||||
* @adapter: I2C device adapter;
|
||||
* @client: I2C device client;
|
||||
* @brdinfo: device board information;
|
||||
|
@ -45,7 +44,7 @@
|
|||
* Structure represents I2C hotplug device static data (board topology) and
|
||||
* dynamic data (related kernel objects handles).
|
||||
*/
|
||||
struct mlxcpld_hotplug_device {
|
||||
struct mlxreg_hotplug_device {
|
||||
struct i2c_adapter *adapter;
|
||||
struct i2c_client *client;
|
||||
struct i2c_board_info brdinfo;
|
||||
|
@ -53,7 +52,7 @@ struct mlxcpld_hotplug_device {
|
|||
};
|
||||
|
||||
/**
|
||||
* struct mlxcpld_hotplug_platform_data - device platform data:
|
||||
* struct mlxreg_hotplug_platform_data - device platform data:
|
||||
* @top_aggr_offset: offset of top aggregation interrupt register;
|
||||
* @top_aggr_mask: top aggregation interrupt common mask;
|
||||
* @top_aggr_psu_mask: top aggregation interrupt PSU mask;
|
||||
|
@ -76,24 +75,24 @@ struct mlxcpld_hotplug_device {
|
|||
* like FAN, PSU, power cable insertion and removing. This data provides the
|
||||
* number of hot-pluggable devices and hardware description for event handling.
|
||||
*/
|
||||
struct mlxcpld_hotplug_platform_data {
|
||||
struct mlxreg_hotplug_platform_data {
|
||||
u16 top_aggr_offset;
|
||||
u8 top_aggr_mask;
|
||||
u8 top_aggr_psu_mask;
|
||||
u16 psu_reg_offset;
|
||||
u8 psu_mask;
|
||||
u8 psu_count;
|
||||
struct mlxcpld_hotplug_device *psu;
|
||||
struct mlxreg_hotplug_device *psu;
|
||||
u8 top_aggr_pwr_mask;
|
||||
u16 pwr_reg_offset;
|
||||
u8 pwr_mask;
|
||||
u8 pwr_count;
|
||||
struct mlxcpld_hotplug_device *pwr;
|
||||
struct mlxreg_hotplug_device *pwr;
|
||||
u8 top_aggr_fan_mask;
|
||||
u16 fan_reg_offset;
|
||||
u8 fan_mask;
|
||||
u8 fan_count;
|
||||
struct mlxcpld_hotplug_device *fan;
|
||||
struct mlxreg_hotplug_device *fan;
|
||||
};
|
||||
|
||||
#endif /* __LINUX_PLATFORM_DATA_MLXCPLD_HOTPLUG_H */
|
||||
#endif /* __LINUX_PLATFORM_DATA_MLXREG_H */
|
Loading…
Add table
Add a link
Reference in a new issue