Changeset 730
- Timestamp:
- Sep 10, 2022, 12:08:43 AM (3 years ago)
- Location:
- GPL/branches/uniaud32-next
- Files:
-
- 5 edited
-
alsa-kernel/include/sound/config.h (modified) (1 diff)
-
alsa-kernel/pci/hda/hda_bind.c (modified) (1 diff)
-
include/linux/device.h (modified) (3 diffs)
-
include/linux/pci.h (modified) (2 diffs)
-
lib32/pci.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
GPL/branches/uniaud32-next/alsa-kernel/include/sound/config.h
r647 r730 31 31 #define CONFIG_SND_HDA_CODEC_CONEXANT 32 32 #define CONFIG_SND_HDA_CODEC_CMEDIA 33 #define CONFIG_SND_HDA_CODEC_HDMI 33 34 #define CONFIG_SND_HDA_CODEC_REALTEK 34 35 #define CONFIG_SND_HDA_CODEC_SIGMATEL -
GPL/branches/uniaud32-next/alsa-kernel/pci/hda/hda_bind.c
r711 r730 245 245 } 246 246 247 #if IS_ENABLED(CONFIG_SND_HDA_CODEC_HDMI) 247 #if IS_ENABLED(CONFIG_SND_HDA_CODEC_HDMI) || defined(CONFIG_SND_HDA_CODEC_HDMI) 248 248 /* if all audio out widgets are digital, let's assume the codec as a HDMI/DP */ 249 249 static bool is_likely_hdmi_codec(struct hda_codec *codec) -
GPL/branches/uniaud32-next/include/linux/device.h
r719 r730 69 69 struct list_head dma_pools; /* dma pools (if dma'ble) */ 70 70 struct device_driver *driver; 71 void *driver_data; /* Driver data, set and get with 72 dev_set_drvdata/dev_get_drvdata */ 71 73 struct pm_dev *pm_dev; 72 74 char bus_id[20]; … … 149 151 extern struct device_driver *driver_find(const char *name, 150 152 struct bus_type *bus); 151 152 #define dev_set_drvdata(dev,ptr) ((dev)->private_data = (ptr))153 #define dev_get_drvdata(dev) (dev)->private_data154 153 155 154 #define MODULE_ALIAS_CHARDEV_MAJOR(x) … … 323 322 return NUMA_NO_NODE; 324 323 } 324 325 static inline void *dev_get_drvdata(const struct device *dev) 326 { 327 return dev->driver_data; 328 } 329 330 static inline void dev_set_drvdata(struct device *dev, void *data) 331 { 332 dev->driver_data = data; 333 } 334 325 335 #endif /* _LINUX_DEVICE_H */ 326 336 -
GPL/branches/uniaud32-next/include/linux/pci.h
r716 r730 672 672 void pci_set_driver_data (struct pci_dev *dev, void *driver_data); 673 673 674 #define pci_get_drvdata(a) pci_get_driver_data(a)675 #define pci_set_drvdata(a,b) pci_set_driver_data(a, b)676 677 674 #define PCI_DEVICE(vend,dev) \ 678 675 .vendor = (vend), .device = (dev), \ … … 739 736 static inline bool pci_dev_run_wake(struct pci_dev *dev) { return 0; } 740 737 738 /* 739 * Similar to the helpers above, these manipulate per-pci_dev 740 * driver-specific data. They are really just a wrapper around 741 * the generic device structure functions of these calls. 742 */ 743 static inline void *pci_get_drvdata(struct pci_dev *pdev) 744 { 745 return dev_get_drvdata(&pdev->dev); 746 } 747 748 static inline void pci_set_drvdata(struct pci_dev *pdev, void *data) 749 { 750 dev_set_drvdata(&pdev->dev, data); 751 } 741 752 /* If you want to know what to call your pci_dev, ask this function. 742 753 * Again, it's a wrapper around the generic device. -
GPL/branches/uniaud32-next/lib32/pci.c
r728 r730 802 802 } 803 803 804 /**805 */806 void pci_set_driver_data (struct pci_dev *dev, void *driver_data)807 {808 if (dev)809 dev->driver_data = driver_data;810 }811 812 /**813 */814 void *pci_get_driver_data (struct pci_dev *dev)815 {816 if (dev)817 return dev->driver_data;818 return 0;819 }820 804 821 805 /** … … 1040 1024 } 1041 1025 1042 struct pci_driver_mapping {1043 struct pci_dev *dev;1044 struct pci_driver *drv;1045 unsigned long dma_mask;1046 void *driver_data;1047 u32 saved_config[16];1048 };1049 1050 #define PCI_MAX_MAPPINGS 641051 static struct pci_driver_mapping drvmap [PCI_MAX_MAPPINGS] = { { NULL, } , };1052 1053 1054 static struct pci_driver_mapping *get_pci_driver_mapping(struct pci_dev *dev)1055 {1056 int i;1057 1058 for (i = 0; i < PCI_MAX_MAPPINGS; i++)1059 if (drvmap[i].dev == dev)1060 return &drvmap[i];1061 return NULL;1062 }1063 1064 struct pci_driver *snd_pci_compat_get_pci_driver(struct pci_dev *dev)1065 {1066 struct pci_driver_mapping *map = get_pci_driver_mapping(dev);1067 if (map)1068 return map->drv;1069 return NULL;1070 }1071 #if 01072 void * pci_get_drvdata (struct pci_dev *dev)1073 {1074 struct pci_driver_mapping *map = get_pci_driver_mapping(dev);1075 if (map)1076 return map->driver_data;1077 return NULL;1078 }1079 1080 1081 void pci_set_drvdata (struct pci_dev *dev, void *driver_data)1082 {1083 struct pci_driver_mapping *map = get_pci_driver_mapping(dev);1084 if (map)1085 map->driver_data = driver_data;1086 }1087 #endif1088 1089 1090 1026 //****************************************************************************** 1091 1027 //******************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.
