|SUCCESS| [2/2] test/sched: check port rate byte clock limits

dpdklab at iol.unh.edu dpdklab at iol.unh.edu
Fri Nov 20 13:02:02 CET 2026


Test-Label: ai-code-review
Test-Status: SUCCESS
https://dpdk.org/patch/173061

_AI Code Review_

=== Patch Review: series.patch (via Claude) ===
Review date: 2026-11-20

**Patch 2/2 (test/sched: check port rate byte clock limits)**

Info: a port leaks if either negative assertion fails.

```
	port_param.rate = UINT64_MAX;
	port = rte_sched_port_config(&port_param);
	TEST_ASSERT_NULL(port, "Port config accepted rate too high\n");
```

If the regression these cases guard against ever comes back, `rte_sched_port_config()` returns a valid port. `TEST_ASSERT_NULL` then returns from `test_sched()` without freeing it. The same applies to the "rate too low" case.

This only matters in a failing test run. If you want the cleanup to be tidy, free the port before reporting the failure:

```
	if (port != NULL) {
		rte_sched_port_free(port);
		TEST_ASSERT(0, ...);
	}
```

Review-Result: CLEAN


More information about the test-report mailing list