Re: [PATCH v3 10/11] net: sched: atomically check-allocate action

2018-05-28 Thread Marcelo Ricardo Leitner
On Mon, May 28, 2018 at 12:17:28AM +0300, Vlad Buslov wrote: > Implement function that atomically checks if action exists and either takes > reference to it, or allocates idr slot for action index to prevent > concurrent allocations of actions with same index. Use EBUSY error pointer > to indicate

Re: [PATCH v3 10/11] net: sched: atomically check-allocate action

2018-05-28 Thread Jiri Pirko
Sun, May 27, 2018 at 11:17:28PM CEST, vla...@mellanox.com wrote: >Implement function that atomically checks if action exists and either takes >reference to it, or allocates idr slot for action index to prevent >concurrent allocations of actions with same index. Use EBUSY error pointer >to indicate

[PATCH v3 10/11] net: sched: atomically check-allocate action

2018-05-27 Thread Vlad Buslov
Implement function that atomically checks if action exists and either takes reference to it, or allocates idr slot for action index to prevent concurrent allocations of actions with same index. Use EBUSY error pointer to indicate that idr slot is reserved. Implement cleanup helper function that