Repository navigation
Commit 42800fc
RDMA/core: Sanitize WQ state received from the userspace
[ Upstream commit f974428 ]
The mlx4 and mlx5 implemented differently the WQ input checks. Instead of
duplicating mlx4 logic in the mlx5, let's prepare the input in the central
place.
The mlx5 implementation didn't check for validity of state input. It is
not real bug because our FW checked that, but still worth to fix.
Fixes: f213c05 ("IB/uverbs: Add WQ support")
Link: https://lore.kernel.org/r/ac41ad6a81b095b1a8ad453dcf62cf8d3c5da779.1621413310.git.leonro@nvidia.com
Reported-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent c470dd3 commit 42800fc
3 files changed
Lines changed: 23 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3000 | 3000 | | |
3001 | 3001 | | |
3002 | 3002 | | |
3003 | | - | |
3004 | | - | |
3005 | 3003 | | |
3006 | 3004 | | |
3007 | 3005 | | |
3008 | 3006 | | |
| 3007 | + | |
| 3008 | + | |
| 3009 | + | |
| 3010 | + | |
| 3011 | + | |
| 3012 | + | |
| 3013 | + | |
| 3014 | + | |
| 3015 | + | |
| 3016 | + | |
| 3017 | + | |
| 3018 | + | |
| 3019 | + | |
| 3020 | + | |
| 3021 | + | |
| 3022 | + | |
| 3023 | + | |
| 3024 | + | |
| 3025 | + | |
3009 | 3026 | | |
3010 | 3027 | | |
3011 | 3028 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4244 | 4244 | | |
4245 | 4245 | | |
4246 | 4246 | | |
4247 | | - | |
4248 | | - | |
4249 | | - | |
4250 | | - | |
4251 | | - | |
4252 | | - | |
4253 | | - | |
| 4247 | + | |
| 4248 | + | |
4254 | 4249 | | |
4255 | 4250 | | |
4256 | 4251 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5236 | 5236 | | |
5237 | 5237 | | |
5238 | 5238 | | |
5239 | | - | |
5240 | | - | |
5241 | | - | |
5242 | | - | |
| 5239 | + | |
| 5240 | + | |
5243 | 5241 | | |
5244 | 5242 | | |
5245 | 5243 | | |
| |||
0 commit comments