On Monday 05 November 2007 11:43, Dmitry Torokhov wrote:
> ACPI: video - remove unsafe uses of list_for_each_safe()
>
> list_for_each_safe() only protects list from list alterations
> performed by the same thread. One still needs to implement
> proper locking when list is being accessed from several threads.
>
> Signed-off-by: Dmitry Torokhov <[EMAIL PROTECTED]>
> ---
> drivers/acpi/video.c | 71
> ++++++++++++++++++++++++---------------------------
> 1 file changed, 34 insertions(+), 37 deletions(-)
>
> Index: work/drivers/acpi/video.c
> ===================================================================
> --- work.orig/drivers/acpi/video.c
> +++ work/drivers/acpi/video.c
> @@ -1462,12 +1462,14 @@ acpi_video_bus_get_one_device(struct acp
>
> static void acpi_video_device_rebind(struct acpi_video_bus *video)
> {
> - struct list_head *node, *next;
> - list_for_each_safe(node, next, &video->video_device_list) {
yeah, these were mis-used -- they're just for the case
where we delete the node inside the loop and don't
want to test the node->next.
applied.
thanks,
-Len
-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html