mirror of
				https://kernel.googlesource.com/pub/scm/linux/kernel/git/stable/linux-stable.git
				synced 2025-10-30 22:47:06 +10:00 
			
		
		
		
	ALSA: hda: tas2781: fix tas2563 EFI data endianness
commite5a00dafc7upstream. Before conversion to unify the calibration data management, the tas2563_apply_calib() function performed the big endian conversion and wrote the calibration data to the device. The writing is now done by the common tasdev_load_calibrated_data() function, but without conversion. Put the values into the calibration data buffer with the expected endianness. Fixes:4fe2385134("ALSA: hda/tas2781: Move and unified the calibrated-data getting function for SPI and I2C into the tas2781_hda lib") Cc: <stable@vger.kernel.org> Signed-off-by: Gergo Koteles <soyer@irl.hu> Link: https://patch.msgid.link/20250829160450.66623-1-soyer@irl.hu Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
		
							parent
							
								
									1dfa6e6660
								
							
						
					
					
						commit
						5601628904
					
				| @ -292,6 +292,7 @@ static int tas2563_save_calibration(struct tas2781_hda *h) | ||||
| 	struct cali_reg *r = &cd->cali_reg_array; | ||||
| 	unsigned int offset = 0; | ||||
| 	unsigned char *data; | ||||
| 	__be32 bedata; | ||||
| 	efi_status_t status; | ||||
| 	unsigned int attr; | ||||
| 	int ret, i, j, k; | ||||
| @ -333,6 +334,8 @@ static int tas2563_save_calibration(struct tas2781_hda *h) | ||||
| 					i, j, status); | ||||
| 				return -EINVAL; | ||||
| 			} | ||||
| 			bedata = cpu_to_be32(*(uint32_t *)&data[offset]); | ||||
| 			memcpy(&data[offset], &bedata, sizeof(bedata)); | ||||
| 			offset += TAS2563_CAL_DATA_SIZE; | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user