nsm, pmc: Check for missing HW time stamps.

As of 510777deca message layer no longer returns -ETIME.  Callers of
msg_post_recv() are expected to check for missing time stamps themselves.
This patch updates the two forgotten call sites.

Fixes: 510777deca ("msg: Move the check for missing HW time stamps into caller.")

Signed-off-by: Richard Cochran <richardcochran@gmail.com>
master
Richard Cochran 2018-04-16 07:28:19 -07:00
parent 0455489158
commit 7a76c36b34
2 changed files with 10 additions and 8 deletions

9
nsm.c
View File

@ -337,16 +337,17 @@ static struct ptp_message *nsm_recv(struct nsm *nsm, int fd)
case -EBADMSG: case -EBADMSG:
pr_err("bad message"); pr_err("bad message");
break; break;
case -ETIME:
pr_err("received %s without timestamp",
msg_type_string(msg_type(msg)));
break;
case -EPROTO: case -EPROTO:
pr_debug("ignoring message"); pr_debug("ignoring message");
break; break;
} }
goto failed; goto failed;
} }
if (msg_sots_missing(msg)) {
pr_err("received %s without timestamp",
msg_type_string(msg_type(msg)));
goto failed;
}
return msg; return msg;
failed: failed:

View File

@ -326,16 +326,17 @@ struct ptp_message *pmc_recv(struct pmc *pmc)
case -EBADMSG: case -EBADMSG:
pr_err("bad message"); pr_err("bad message");
break; break;
case -ETIME:
pr_err("received %s without timestamp",
msg_type_string(msg_type(msg)));
break;
case -EPROTO: case -EPROTO:
pr_debug("ignoring message"); pr_debug("ignoring message");
break; break;
} }
goto failed; goto failed;
} }
if (msg_sots_missing(msg)) {
pr_err("received %s without timestamp",
msg_type_string(msg_type(msg)));
goto failed;
}
return msg; return msg;
failed: failed: