RE: [PATCH 1/3] ACPI/Thermal: Remove the unused lock of struct acpi_thermal

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: linux-acpi-owner@xxxxxxxxxxxxxxx [mailto:linux-acpi-
> owner@xxxxxxxxxxxxxxx] On Behalf Of tianyu.lan@xxxxxxxxx
> Sent: Wednesday, August 14, 2013 6:31 PM
> To: rjw@xxxxxxx; lenb@xxxxxxxxxx
> Cc: Lan, Tianyu; linux-acpi@xxxxxxxxxxxxxxx; Zhang, Rui
> Subject: [PATCH 1/3] ACPI/Thermal: Remove the unused lock of struct
> acpi_thermal
> 
> From: Lan Tianyu <tianyu.lan@xxxxxxxxx>
> 
> The acpi_thermal->lock now just is initialized when thermal zone device
> is added and destroyed when thermal zone is removed. Never being used
> any other places. So remove it.
> 

Hi Tianyu,

Very Nice catch. All three patches look fine to me.
For all three,
Acked-by: Durgadoss R <durgadoss.r@xxxxxxxxx>

Thanks,
Durga

> Acked-by: Zhang Rui <rui.zhang@xxxxxxxxx>
> Signed-off-by: Lan Tianyu <tianyu.lan@xxxxxxxxx>
> ---
>  drivers/acpi/thermal.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/drivers/acpi/thermal.c b/drivers/acpi/thermal.c
> index a3e38a0..850818d 100644
> --- a/drivers/acpi/thermal.c
> +++ b/drivers/acpi/thermal.c
> @@ -190,7 +190,6 @@ struct acpi_thermal {
>  	struct thermal_zone_device *thermal_zone;
>  	int tz_enabled;
>  	int kelvin_offset;
> -	struct mutex lock;
>  };
> 
>  /* --------------------------------------------------------------------------
> @@ -1088,8 +1087,6 @@ static int acpi_thermal_add(struct acpi_device *device)
>  	strcpy(acpi_device_name(device), ACPI_THERMAL_DEVICE_NAME);
>  	strcpy(acpi_device_class(device), ACPI_THERMAL_CLASS);
>  	device->driver_data = tz;
> -	mutex_init(&tz->lock);
> -
> 
>  	result = acpi_thermal_get_info(tz);
>  	if (result)
> @@ -1122,7 +1119,6 @@ static int acpi_thermal_remove(struct acpi_device
> *device)
>  	tz = acpi_driver_data(device);
> 
>  	acpi_thermal_unregister_thermal_zone(tz);
> -	mutex_destroy(&tz->lock);
>  	kfree(tz);
>  	return 0;
>  }
> --
> 1.8.4.rc0.1.g8f6a3e5.dirty
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux