@@ -81,17 +81,17 @@ nvkm_event_ntfy_state(struct nvkm_event_ntfy *ntfy)
81
81
static void
82
82
nvkm_event_ntfy_remove (struct nvkm_event_ntfy * ntfy )
83
83
{
84
- spin_lock_irq (& ntfy -> event -> list_lock );
84
+ write_lock_irq (& ntfy -> event -> list_lock );
85
85
list_del_init (& ntfy -> head );
86
- spin_unlock_irq (& ntfy -> event -> list_lock );
86
+ write_unlock_irq (& ntfy -> event -> list_lock );
87
87
}
88
88
89
89
static void
90
90
nvkm_event_ntfy_insert (struct nvkm_event_ntfy * ntfy )
91
91
{
92
- spin_lock_irq (& ntfy -> event -> list_lock );
92
+ write_lock_irq (& ntfy -> event -> list_lock );
93
93
list_add_tail (& ntfy -> head , & ntfy -> event -> ntfy );
94
- spin_unlock_irq (& ntfy -> event -> list_lock );
94
+ write_unlock_irq (& ntfy -> event -> list_lock );
95
95
}
96
96
97
97
static void
@@ -176,7 +176,7 @@ nvkm_event_ntfy(struct nvkm_event *event, int id, u32 bits)
176
176
return ;
177
177
178
178
nvkm_trace (event -> subdev , "event: ntfy %08x on %d\n" , bits , id );
179
- spin_lock_irqsave (& event -> list_lock , flags );
179
+ read_lock_irqsave (& event -> list_lock , flags );
180
180
181
181
list_for_each_entry_safe (ntfy , ntmp , & event -> ntfy , head ) {
182
182
if (ntfy -> id == id && ntfy -> bits & bits ) {
@@ -185,7 +185,7 @@ nvkm_event_ntfy(struct nvkm_event *event, int id, u32 bits)
185
185
}
186
186
}
187
187
188
- spin_unlock_irqrestore (& event -> list_lock , flags );
188
+ read_unlock_irqrestore (& event -> list_lock , flags );
189
189
}
190
190
191
191
void
0 commit comments