diff options
| author | Takashi Iwai <tiwai@suse.de> | 2015-03-06 08:25:27 -0500 |
|---|---|---|
| committer | Takashi Iwai <tiwai@suse.de> | 2015-03-06 08:25:27 -0500 |
| commit | a52afea68f94d2501b7fe1fa18cc6acf84e35a76 (patch) | |
| tree | 977eb066b9de1bea4e7ce7ea9a5583d00279061f /include | |
| parent | 8b28c93fe5a55873ce22b7126e84eb59290f8603 (diff) | |
| parent | d7e3281b52fea8917fb4a7a5b09df5e6a9d2850c (diff) | |
Merge tag 'asoc-v4.1' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: Changes for v4.1
A selection of changes for v4.1 so far. The main things are:
- Move of jack registration to the card where it belongs.
- Support for DAPM routes specified by both the machine driver and DT.
Diffstat (limited to 'include')
| -rw-r--r-- | include/drm/i915_pciids.h | 4 | ||||
| -rw-r--r-- | include/linux/hid-sensor-hub.h | 5 | ||||
| -rw-r--r-- | include/linux/thermal.h | 56 | ||||
| -rw-r--r-- | include/sound/pcm_params.h | 7 | ||||
| -rw-r--r-- | include/sound/soc.h | 16 | ||||
| -rw-r--r-- | include/xen/xen-ops.h | 26 |
6 files changed, 107 insertions, 7 deletions
diff --git a/include/drm/i915_pciids.h b/include/drm/i915_pciids.h index 180ad0e6de21..d016dc57f007 100644 --- a/include/drm/i915_pciids.h +++ b/include/drm/i915_pciids.h | |||
| @@ -214,9 +214,9 @@ | |||
| 214 | INTEL_VGA_DEVICE((((gt) - 1) << 4) | (id), info) | 214 | INTEL_VGA_DEVICE((((gt) - 1) << 4) | (id), info) |
| 215 | 215 | ||
| 216 | #define _INTEL_BDW_M_IDS(gt, info) \ | 216 | #define _INTEL_BDW_M_IDS(gt, info) \ |
| 217 | _INTEL_BDW_M(gt, 0x1602, info), /* ULT */ \ | 217 | _INTEL_BDW_M(gt, 0x1602, info), /* Halo */ \ |
| 218 | _INTEL_BDW_M(gt, 0x1606, info), /* ULT */ \ | 218 | _INTEL_BDW_M(gt, 0x1606, info), /* ULT */ \ |
| 219 | _INTEL_BDW_M(gt, 0x160B, info), /* Iris */ \ | 219 | _INTEL_BDW_M(gt, 0x160B, info), /* ULT */ \ |
| 220 | _INTEL_BDW_M(gt, 0x160E, info) /* ULX */ | 220 | _INTEL_BDW_M(gt, 0x160E, info) /* ULX */ |
| 221 | 221 | ||
| 222 | #define _INTEL_BDW_D_IDS(gt, info) \ | 222 | #define _INTEL_BDW_D_IDS(gt, info) \ |
diff --git a/include/linux/hid-sensor-hub.h b/include/linux/hid-sensor-hub.h index 51f7ccadf923..4173a8fdad9e 100644 --- a/include/linux/hid-sensor-hub.h +++ b/include/linux/hid-sensor-hub.h | |||
| @@ -33,6 +33,8 @@ | |||
| 33 | * @units: Measurment unit for this attribute. | 33 | * @units: Measurment unit for this attribute. |
| 34 | * @unit_expo: Exponent used in the data. | 34 | * @unit_expo: Exponent used in the data. |
| 35 | * @size: Size in bytes for data size. | 35 | * @size: Size in bytes for data size. |
| 36 | * @logical_minimum: Logical minimum value for this attribute. | ||
| 37 | * @logical_maximum: Logical maximum value for this attribute. | ||
| 36 | */ | 38 | */ |
| 37 | struct hid_sensor_hub_attribute_info { | 39 | struct hid_sensor_hub_attribute_info { |
| 38 | u32 usage_id; | 40 | u32 usage_id; |
| @@ -146,6 +148,7 @@ int sensor_hub_input_get_attribute_info(struct hid_sensor_hub_device *hsdev, | |||
| 146 | 148 | ||
| 147 | /** | 149 | /** |
| 148 | * sensor_hub_input_attr_get_raw_value() - Synchronous read request | 150 | * sensor_hub_input_attr_get_raw_value() - Synchronous read request |
| 151 | * @hsdev: Hub device instance. | ||
| 149 | * @usage_id: Attribute usage id of parent physical device as per spec | 152 | * @usage_id: Attribute usage id of parent physical device as per spec |
| 150 | * @attr_usage_id: Attribute usage id as per spec | 153 | * @attr_usage_id: Attribute usage id as per spec |
| 151 | * @report_id: Report id to look for | 154 | * @report_id: Report id to look for |
| @@ -160,6 +163,7 @@ int sensor_hub_input_attr_get_raw_value(struct hid_sensor_hub_device *hsdev, | |||
| 160 | u32 attr_usage_id, u32 report_id); | 163 | u32 attr_usage_id, u32 report_id); |
| 161 | /** | 164 | /** |
| 162 | * sensor_hub_set_feature() - Feature set request | 165 | * sensor_hub_set_feature() - Feature set request |
| 166 | * @hsdev: Hub device instance. | ||
| 163 | * @report_id: Report id to look for | 167 | * @report_id: Report id to look for |
| 164 | * @field_index: Field index inside a report | 168 | * @field_index: Field index inside a report |
| 165 | * @value: Value to set | 169 | * @value: Value to set |
| @@ -172,6 +176,7 @@ int sensor_hub_set_feature(struct hid_sensor_hub_device *hsdev, u32 report_id, | |||
| 172 | 176 | ||
| 173 | /** | 177 | /** |
| 174 | * sensor_hub_get_feature() - Feature get request | 178 | * sensor_hub_get_feature() - Feature get request |
| 179 | * @hsdev: Hub device instance. | ||
| 175 | * @report_id: Report id to look for | 180 | * @report_id: Report id to look for |
| 176 | * @field_index: Field index inside a report | 181 | * @field_index: Field index inside a report |
| 177 | * @value: Place holder for return value | 182 | * @value: Place holder for return value |
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index fc52e307efab..5eac316490ea 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h | |||
| @@ -314,6 +314,8 @@ void thermal_zone_of_sensor_unregister(struct device *dev, | |||
| 314 | } | 314 | } |
| 315 | 315 | ||
| 316 | #endif | 316 | #endif |
| 317 | |||
| 318 | #if IS_ENABLED(CONFIG_THERMAL) | ||
| 317 | struct thermal_zone_device *thermal_zone_device_register(const char *, int, int, | 319 | struct thermal_zone_device *thermal_zone_device_register(const char *, int, int, |
| 318 | void *, struct thermal_zone_device_ops *, | 320 | void *, struct thermal_zone_device_ops *, |
| 319 | const struct thermal_zone_params *, int, int); | 321 | const struct thermal_zone_params *, int, int); |
| @@ -340,8 +342,58 @@ struct thermal_instance *get_thermal_instance(struct thermal_zone_device *, | |||
| 340 | struct thermal_cooling_device *, int); | 342 | struct thermal_cooling_device *, int); |
| 341 | void thermal_cdev_update(struct thermal_cooling_device *); | 343 | void thermal_cdev_update(struct thermal_cooling_device *); |
| 342 | void thermal_notify_framework(struct thermal_zone_device *, int); | 344 | void thermal_notify_framework(struct thermal_zone_device *, int); |
| 343 | 345 | #else | |
| 344 | #ifdef CONFIG_NET | 346 | static inline struct thermal_zone_device *thermal_zone_device_register( |
| 347 | const char *type, int trips, int mask, void *devdata, | ||
| 348 | struct thermal_zone_device_ops *ops, | ||
| 349 | const struct thermal_zone_params *tzp, | ||
| 350 | int passive_delay, int polling_delay) | ||
| 351 | { return ERR_PTR(-ENODEV); } | ||
| 352 | static inline void thermal_zone_device_unregister( | ||
| 353 | struct thermal_zone_device *tz) | ||
| 354 | { } | ||
| 355 | static inline int thermal_zone_bind_cooling_device( | ||
| 356 | struct thermal_zone_device *tz, int trip, | ||
| 357 | struct thermal_cooling_device *cdev, | ||
| 358 | unsigned long upper, unsigned long lower) | ||
| 359 | { return -ENODEV; } | ||
| 360 | static inline int thermal_zone_unbind_cooling_device( | ||
| 361 | struct thermal_zone_device *tz, int trip, | ||
| 362 | struct thermal_cooling_device *cdev) | ||
| 363 | { return -ENODEV; } | ||
| 364 | static inline void thermal_zone_device_update(struct thermal_zone_device *tz) | ||
| 365 | { } | ||
| 366 | static inline struct thermal_cooling_device * | ||
| 367 | thermal_cooling_device_register(char *type, void *devdata, | ||
| 368 | const struct thermal_cooling_device_ops *ops) | ||
| 369 | { return ERR_PTR(-ENODEV); } | ||
| 370 | static inline struct thermal_cooling_device * | ||
| 371 | thermal_of_cooling_device_register(struct device_node *np, | ||
| 372 | char *type, void *devdata, const struct thermal_cooling_device_ops *ops) | ||
| 373 | { return ERR_PTR(-ENODEV); } | ||
| 374 | static inline void thermal_cooling_device_unregister( | ||
| 375 | struct thermal_cooling_device *cdev) | ||
| 376 | { } | ||
| 377 | static inline struct thermal_zone_device *thermal_zone_get_zone_by_name( | ||
| 378 | const char *name) | ||
| 379 | { return ERR_PTR(-ENODEV); } | ||
| 380 | static inline int thermal_zone_get_temp( | ||
| 381 | struct thermal_zone_device *tz, unsigned long *temp) | ||
| 382 | { return -ENODEV; } | ||
| 383 | static inline int get_tz_trend(struct thermal_zone_device *tz, int trip) | ||
| 384 | { return -ENODEV; } | ||
| 385 | static inline struct thermal_instance * | ||
| 386 | get_thermal_instance(struct thermal_zone_device *tz, | ||
| 387 | struct thermal_cooling_device *cdev, int trip) | ||
| 388 | { return ERR_PTR(-ENODEV); } | ||
| 389 | static inline void thermal_cdev_update(struct thermal_cooling_device *cdev) | ||
| 390 | { } | ||
| 391 | static inline void thermal_notify_framework(struct thermal_zone_device *tz, | ||
| 392 | int trip) | ||
| 393 | { } | ||
| 394 | #endif /* CONFIG_THERMAL */ | ||
| 395 | |||
| 396 | #if defined(CONFIG_NET) && IS_ENABLED(CONFIG_THERMAL) | ||
| 345 | extern int thermal_generate_netlink_event(struct thermal_zone_device *tz, | 397 | extern int thermal_generate_netlink_event(struct thermal_zone_device *tz, |
| 346 | enum events event); | 398 | enum events event); |
| 347 | #else | 399 | #else |
diff --git a/include/sound/pcm_params.h b/include/sound/pcm_params.h index 3c45f3924ba7..c704357775fc 100644 --- a/include/sound/pcm_params.h +++ b/include/sound/pcm_params.h | |||
| @@ -366,4 +366,11 @@ static inline int params_physical_width(const struct snd_pcm_hw_params *p) | |||
| 366 | return snd_pcm_format_physical_width(params_format(p)); | 366 | return snd_pcm_format_physical_width(params_format(p)); |
| 367 | } | 367 | } |
| 368 | 368 | ||
| 369 | static inline void | ||
| 370 | params_set_format(struct snd_pcm_hw_params *p, snd_pcm_format_t fmt) | ||
| 371 | { | ||
| 372 | snd_mask_set(hw_param_mask(p, SNDRV_PCM_HW_PARAM_FORMAT), | ||
| 373 | (__force int)fmt); | ||
| 374 | } | ||
| 375 | |||
| 369 | #endif /* __SOUND_PCM_PARAMS_H */ | 376 | #endif /* __SOUND_PCM_PARAMS_H */ |
diff --git a/include/sound/soc.h b/include/sound/soc.h index cf0bb156d6da..b371aef9819f 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h | |||
| @@ -450,8 +450,10 @@ int soc_dai_hw_params(struct snd_pcm_substream *substream, | |||
| 450 | struct snd_soc_dai *dai); | 450 | struct snd_soc_dai *dai); |
| 451 | 451 | ||
| 452 | /* Jack reporting */ | 452 | /* Jack reporting */ |
| 453 | int snd_soc_jack_new(struct snd_soc_codec *codec, const char *id, int type, | 453 | int snd_soc_card_jack_new(struct snd_soc_card *card, const char *id, int type, |
| 454 | struct snd_soc_jack *jack); | 454 | struct snd_soc_jack *jack, struct snd_soc_jack_pin *pins, |
| 455 | unsigned int num_pins); | ||
| 456 | |||
| 455 | void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask); | 457 | void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask); |
| 456 | int snd_soc_jack_add_pins(struct snd_soc_jack *jack, int count, | 458 | int snd_soc_jack_add_pins(struct snd_soc_jack *jack, int count, |
| 457 | struct snd_soc_jack_pin *pins); | 459 | struct snd_soc_jack_pin *pins); |
| @@ -659,7 +661,7 @@ struct snd_soc_jack_gpio { | |||
| 659 | struct snd_soc_jack { | 661 | struct snd_soc_jack { |
| 660 | struct mutex mutex; | 662 | struct mutex mutex; |
| 661 | struct snd_jack *jack; | 663 | struct snd_jack *jack; |
| 662 | struct snd_soc_codec *codec; | 664 | struct snd_soc_card *card; |
| 663 | struct list_head pins; | 665 | struct list_head pins; |
| 664 | int status; | 666 | int status; |
| 665 | struct blocking_notifier_head notifier; | 667 | struct blocking_notifier_head notifier; |
| @@ -954,6 +956,9 @@ struct snd_soc_dai_link { | |||
| 954 | unsigned int symmetric_channels:1; | 956 | unsigned int symmetric_channels:1; |
| 955 | unsigned int symmetric_samplebits:1; | 957 | unsigned int symmetric_samplebits:1; |
| 956 | 958 | ||
| 959 | /* Mark this pcm with non atomic ops */ | ||
| 960 | bool nonatomic; | ||
| 961 | |||
| 957 | /* Do not create a PCM for this DAI link (Backend link) */ | 962 | /* Do not create a PCM for this DAI link (Backend link) */ |
| 958 | unsigned int no_pcm:1; | 963 | unsigned int no_pcm:1; |
| 959 | 964 | ||
| @@ -1071,11 +1076,16 @@ struct snd_soc_card { | |||
| 1071 | 1076 | ||
| 1072 | /* | 1077 | /* |
| 1073 | * Card-specific routes and widgets. | 1078 | * Card-specific routes and widgets. |
| 1079 | * Note: of_dapm_xxx for Device Tree; Otherwise for driver build-in. | ||
| 1074 | */ | 1080 | */ |
| 1075 | const struct snd_soc_dapm_widget *dapm_widgets; | 1081 | const struct snd_soc_dapm_widget *dapm_widgets; |
| 1076 | int num_dapm_widgets; | 1082 | int num_dapm_widgets; |
| 1077 | const struct snd_soc_dapm_route *dapm_routes; | 1083 | const struct snd_soc_dapm_route *dapm_routes; |
| 1078 | int num_dapm_routes; | 1084 | int num_dapm_routes; |
| 1085 | const struct snd_soc_dapm_widget *of_dapm_widgets; | ||
| 1086 | int num_of_dapm_widgets; | ||
| 1087 | const struct snd_soc_dapm_route *of_dapm_routes; | ||
| 1088 | int num_of_dapm_routes; | ||
| 1079 | bool fully_routed; | 1089 | bool fully_routed; |
| 1080 | 1090 | ||
| 1081 | struct work_struct deferred_resume_work; | 1091 | struct work_struct deferred_resume_work; |
diff --git a/include/xen/xen-ops.h b/include/xen/xen-ops.h index 7491ee5d8164..83338210ee04 100644 --- a/include/xen/xen-ops.h +++ b/include/xen/xen-ops.h | |||
| @@ -46,4 +46,30 @@ static inline efi_system_table_t __init *xen_efi_probe(void) | |||
| 46 | } | 46 | } |
| 47 | #endif | 47 | #endif |
| 48 | 48 | ||
| 49 | #ifdef CONFIG_PREEMPT | ||
| 50 | |||
| 51 | static inline void xen_preemptible_hcall_begin(void) | ||
| 52 | { | ||
| 53 | } | ||
| 54 | |||
| 55 | static inline void xen_preemptible_hcall_end(void) | ||
| 56 | { | ||
| 57 | } | ||
| 58 | |||
| 59 | #else | ||
| 60 | |||
| 61 | DECLARE_PER_CPU(bool, xen_in_preemptible_hcall); | ||
| 62 | |||
| 63 | static inline void xen_preemptible_hcall_begin(void) | ||
| 64 | { | ||
| 65 | __this_cpu_write(xen_in_preemptible_hcall, true); | ||
| 66 | } | ||
| 67 | |||
| 68 | static inline void xen_preemptible_hcall_end(void) | ||
| 69 | { | ||
| 70 | __this_cpu_write(xen_in_preemptible_hcall, false); | ||
| 71 | } | ||
| 72 | |||
| 73 | #endif /* CONFIG_PREEMPT */ | ||
| 74 | |||
| 49 | #endif /* INCLUDE_XEN_OPS_H */ | 75 | #endif /* INCLUDE_XEN_OPS_H */ |
