1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-01 09:24:10 +01:00

OP-914 - Converted PIOS_RFM22B_Validate back into a normal function from an inline.

This commit is contained in:
Brian Webb 2013-04-16 14:56:21 +01:00
parent 9bb3b5870c
commit bb6986ea04
2 changed files with 11 additions and 11 deletions

View File

@ -790,6 +790,16 @@ bool PIOS_RFM22B_LinkStatus(uint32_t rfm22b_id)
return (rfm22_isConnected(rfm22b_dev) && (rfm22b_dev->stats.link_quality > RFM22B_LINK_QUALITY_THRESHOLD));
}
/**
* Validate that the device structure is valid.
*
* @param[in] rfm22b_dev The RFM22B device structure pointer.
*/
inline bool PIOS_RFM22B_Validate(struct pios_rfm22b_dev *rfm22b_dev)
{
return (rfm22b_dev != NULL && rfm22b_dev->magic == PIOS_RFM22B_DEV_MAGIC);
}
/*****************************************************************************
* The Device Control Thread

View File

@ -758,17 +758,7 @@ struct pios_rfm22b_dev {
// External function definitions
bool PIOS_RFM22_EXT_Int(void);
void PIOS_RFM22B_InjectEvent(struct pios_rfm22b_dev *rfm22b_dev, enum pios_rfm22b_event event, bool inISR);
/**
* Validate that the device structure is valid.
*
* @param[in] rfm22b_dev The RFM22B device structure pointer.
*/
inline bool PIOS_RFM22B_Validate(struct pios_rfm22b_dev *rfm22b_dev)
{
return (rfm22b_dev != NULL && rfm22b_dev->magic == PIOS_RFM22B_DEV_MAGIC);
}
bool PIOS_RFM22B_Validate(struct pios_rfm22b_dev *rfm22b_dev);
// Global variable definitions