Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109993214
D20999.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
3 KB
Referenced Files
None
Subscribers
None
D20999.diff
View Options
Index: head/sys/dev/nvme/nvme_ctrlr.c
===================================================================
--- head/sys/dev/nvme/nvme_ctrlr.c
+++ head/sys/dev/nvme/nvme_ctrlr.c
@@ -181,7 +181,7 @@
{
int i;
- ctrlr->is_failed = TRUE;
+ ctrlr->is_failed = true;
nvme_admin_qpair_disable(&ctrlr->adminq);
nvme_qpair_fail(&ctrlr->adminq);
if (ctrlr->ioq != NULL) {
@@ -546,7 +546,7 @@
return (0);
}
-static boolean_t
+static bool
is_log_page_id_valid(uint8_t page_id)
{
@@ -558,10 +558,10 @@
case NVME_LOG_COMMAND_EFFECT:
case NVME_LOG_RES_NOTIFICATION:
case NVME_LOG_SANITIZE_STATUS:
- return (TRUE);
+ return (true);
}
- return (FALSE);
+ return (false);
}
static uint32_t
@@ -782,7 +782,7 @@
* Disable timeout here, since asynchronous event requests should by
* nature never be timed out.
*/
- req->timeout = FALSE;
+ req->timeout = false;
req->cmd.opc = NVME_OPC_ASYNC_EVENT_REQUEST;
nvme_ctrlr_submit_admin_request(ctrlr, req);
}
@@ -1198,7 +1198,7 @@
TASK_INIT(&ctrlr->reset_task, 0, nvme_ctrlr_reset_task, ctrlr);
TASK_INIT(&ctrlr->fail_req_task, 0, nvme_ctrlr_fail_req_task, ctrlr);
STAILQ_INIT(&ctrlr->fail_req);
- ctrlr->is_failed = FALSE;
+ ctrlr->is_failed = false;
make_dev_args_init(&md_args);
md_args.mda_devsw = &nvme_ctrlr_cdevsw;
Index: head/sys/dev/nvme/nvme_private.h
===================================================================
--- head/sys/dev/nvme/nvme_private.h
+++ head/sys/dev/nvme/nvme_private.h
@@ -141,7 +141,7 @@
} u;
uint32_t type;
uint32_t payload_size;
- boolean_t timeout;
+ bool timeout;
nvme_cb_fn_t cb_fn;
void *cb_arg;
int32_t retries;
@@ -214,7 +214,7 @@
struct nvme_tracker **act_tr;
- boolean_t is_enabled;
+ bool is_enabled;
struct mtx lock __aligned(CACHE_LINE_SIZE);
@@ -322,7 +322,7 @@
uint32_t is_initialized;
uint32_t notification_sent;
- boolean_t is_failed;
+ bool is_failed;
STAILQ_HEAD(, nvme_request) fail_req;
};
@@ -487,7 +487,7 @@
if (req != NULL) {
req->cb_fn = cb_fn;
req->cb_arg = cb_arg;
- req->timeout = TRUE;
+ req->timeout = true;
}
return (req);
}
Index: head/sys/dev/nvme/nvme_qpair.c
===================================================================
--- head/sys/dev/nvme/nvme_qpair.c
+++ head/sys/dev/nvme/nvme_qpair.c
@@ -357,7 +357,7 @@
cpl->cdw0);
}
-static boolean_t
+static bool
nvme_completion_is_retry(const struct nvme_completion *cpl)
{
uint8_t sct, sc, dnr;
@@ -423,7 +423,7 @@
{
struct nvme_qpair * qpair = tr->qpair;
struct nvme_request *req;
- boolean_t retry, error, retriable;
+ bool retry, error, retriable;
req = tr->req;
error = nvme_completion_is_error(cpl);
@@ -508,7 +508,7 @@
struct nvme_request *req, uint32_t sct, uint32_t sc)
{
struct nvme_completion cpl;
- boolean_t error;
+ bool error;
memset(&cpl, 0, sizeof(cpl));
cpl.sqid = qpair->id;
@@ -1127,7 +1127,7 @@
nvme_qpair_enable(struct nvme_qpair *qpair)
{
- qpair->is_enabled = TRUE;
+ qpair->is_enabled = true;
}
void
@@ -1215,7 +1215,7 @@
{
struct nvme_tracker *tr;
- qpair->is_enabled = FALSE;
+ qpair->is_enabled = false;
mtx_lock(&qpair->lock);
TAILQ_FOREACH(tr, &qpair->outstanding_tr, tailq)
callout_stop(&tr->timer);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Feb 13, 4:59 AM (20 h, 53 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16622912
Default Alt Text
D20999.diff (3 KB)
Attached To
Mode
D20999: Move to using bool instead of boolean_t
Attached
Detach File
Event Timeline
Log In to Comment