Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F177901659
D30612.1795550243.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D30612.1795550243.diff
View Options
Index: sys/dev/qlnx/qlnxe/ecore_spq.c
===================================================================
--- sys/dev/qlnx/qlnxe/ecore_spq.c
+++ sys/dev/qlnx/qlnxe/ecore_spq.c
@@ -780,16 +780,17 @@
* entry in the unlimited_pending pool.
*
* @param p_hwfn
- * @param p_ent
+ * @param p_entp
* @param priority
*
* @return enum _ecore_status_t
*/
static enum _ecore_status_t ecore_spq_add_entry(struct ecore_hwfn *p_hwfn,
- struct ecore_spq_entry *p_ent,
+ struct ecore_spq_entry **p_entp,
enum spq_priority priority)
{
- struct ecore_spq *p_spq = p_hwfn->p_spq;
+ struct ecore_spq *p_spq = p_hwfn->p_spq;
+ struct ecore_spq_entry *p_ent = *p_entp;
if (p_ent->queue == &p_spq->unlimited_pending) {
if (OSAL_LIST_IS_EMPTY(&p_spq->free_pool)) {
@@ -820,6 +821,7 @@
OSAL_FREE(p_hwfn->p_dev, p_ent);
p_ent = p_en2;
+ *p_entp = p_ent;
}
}
@@ -913,7 +915,7 @@
#endif
OSAL_LIST_REMOVE_ENTRY(&p_ent->list, &p_spq->unlimited_pending);
- ecore_spq_add_entry(p_hwfn, p_ent, p_ent->priority);
+ ecore_spq_add_entry(p_hwfn, &p_ent, p_ent->priority);
}
return ecore_spq_post_list(p_hwfn, &p_spq->pending,
@@ -956,7 +958,7 @@
goto spq_post_fail;
/* Add the request to the pending queue */
- rc = ecore_spq_add_entry(p_hwfn, p_ent, p_ent->priority);
+ rc = ecore_spq_add_entry(p_hwfn, &p_ent, p_ent->priority);
if (rc)
goto spq_post_fail;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 24, 7:57 PM (4 h, 36 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41962282
Default Alt Text
D30612.1795550243.diff (1 KB)
Attached To
Mode
D30612: qlnxe: Fix a use-after-free in ecore_spq_post()
Attached
Detach File
Event Timeline