mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
cxl: Add cxl_num_decoders_committed() usage to cxl_test
Commit 458ba8189c ("cxl: Add cxl_decoders_committed() helper") missed the
conversion for cxl_test. Add usage of cxl_num_decoders_committed() to
replace the open coding.
Suggested-by: Alison Schofield <alison.schofield@intel.com>
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Reviewed-by: Fan Ni <fan.ni@samsung.com>
Link: https://lore.kernel.org/r/169929160525.824083.11813222229025394254.stgit@djiang5-mobl3
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
This commit is contained in:
@@ -669,10 +669,11 @@ static int mock_decoder_commit(struct cxl_decoder *cxld)
|
||||
return 0;
|
||||
|
||||
dev_dbg(&port->dev, "%s commit\n", dev_name(&cxld->dev));
|
||||
if (port->commit_end + 1 != id) {
|
||||
if (cxl_num_decoders_committed(port) != id) {
|
||||
dev_dbg(&port->dev,
|
||||
"%s: out of order commit, expected decoder%d.%d\n",
|
||||
dev_name(&cxld->dev), port->id, port->commit_end + 1);
|
||||
dev_name(&cxld->dev), port->id,
|
||||
cxl_num_decoders_committed(port));
|
||||
return -EBUSY;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user