History

firewire: core: obsolete usage of GFP_ATOMIC at building node tree

The flag of GFP_ATOMIC is given to the call of kmalloc when building node tree, but the call is not atomic context. The call of fw_core_handle_bus_reset() and fw_core_remove_card() builds the tree, while they are done in specific workqueue or pci remove callback. This commit obsolete the usage of GFP_ATOMIC.

Takashi Sakamoto committed 3 years ago

Commit 06f45431 parent 5716e582 files · +2 −2Browse files

Unified · Split

2 files
  1. drivers/firewire/core-device.c +1 −1
  2. drivers/firewire/core-topology.c +1 −1
drivers/firewire/core-device.c+1−1
@@ -1211,7 +1211,7 @@ void fw_node_event(struct fw_card *card, struct fw_node *node, int event) · 1210 unmodified lines
1211 * without actually having a link.1211 * without actually having a link.
1212 */1212 */
1213 create:1213 create:
1214 device = kzalloc(sizeof(*device), GFP_ATOMIC);1214 device = kzalloc(sizeof(*device), GFP_KERNEL);
1215 if (device == NULL)1215 if (device == NULL)
1216 break;1216 break;
1217 1217
drivers/firewire/core-topology.c+1−1
@@ -101,7 +101,7 @@ static struct fw_node *fw_node_create(u32 sid, int port_count, int color) · 100 unmodified lines
101{101{
102 struct fw_node *node;102 struct fw_node *node;
103 103
104 node = kzalloc(struct_size(node, ports, port_count), GFP_ATOMIC);104 node = kzalloc(struct_size(node, ports, port_count), GFP_KERNEL);
105 if (node == NULL)105 if (node == NULL)
106 return NULL;106 return NULL;
107 107

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t