FreeBSD/sys/dev/isci/scil/scic_sds_phy.c
/**
 * @brief This method returns the port currently containing this phy.
 *        If the phy is currently contained by the dummy port, then
 *        the phy is considered to not be part of a port.
 *
 * @param[in] this_phy This parameter specifies the phy for which to
 *            retrieve the containing port.
 *
 * @return This method returns a handle to a port that contains
 *         the supplied phy.
 * @retval SCI_INVALID_HANDLE This value is returned if the phy is not
 *         part of a real port (i.e. it's contained in the dummy port).
 * @retval !SCI_INVALID_HANDLE All other values indicate a handle/pointer
 *         to the port containing the phy.
 */
@brief This method returns the port currently containing this phy.
If the phy is currently contained by the dummy port, then
the phy is considered to not be part of a port.

@param[in] this_phy This parameter specifies the phy for which to
retrieve the containing port.

@return This method returns a handle to a port that contains
the supplied phy.
@retval SCI_INVALID_HANDLE This value is returned if the phy is not
part of a real port .
@retval !SCI_INVALID_HANDLE All other values indicate a handle/pointer
to the port containing the phy.
@brief This method returns the port currently containing this phy . If the phy is currently contained by the dummy port then the phy is considered to not be part of a port . @param [ in ] this_phy This parameter specifies the phy for which to retrieve the containing port . @return This method returns a handle to a port that contains the supplied phy . @retval SCI_INVALID_HANDLE This value is returned if the phy is not part of a real port . @retval !SCI_INVALID_HANDLE All other values indicate a handle / pointer to the port containing the phy .
SCI_PORT_HANDLE_T scic_sds_phy_get_port(
   SCIC_SDS_PHY_T *this_phy
)
{
   SCIC_LOG_TRACE((
      sci_base_object_get_logger(this_phy),
      SCIC_LOG_OBJECT_PHY,
      "scic_phy_get_port(0x%x) enter\n",
      this_phy
   ));
   if (scic_sds_port_get_index(this_phy->owning_port) == SCIC_SDS_DUMMY_PORT)
      return SCI_INVALID_HANDLE;
   return this_phy->owning_port;
}
SCI_PORT_HANDLE_T scic_sds_phy_get_port ( SCIC_SDS_PHY_T * this_phy ) { SCIC_LOG_TRACE ( ( sci_base_object_get_logger ( this_phy ) , SCIC_LOG_OBJECT_PHY , " \n " , this_phy ) ) ; if ( scic_sds_port_get_index ( this_phy -> owning_port ) == SCIC_SDS_DUMMY_PORT ) return SCI_INVALID_HANDLE ; return this_phy -> owning_port ; }
@brief This method returns the port currently containing this phy.
@brief This method returns the port currently containing this phy .