FreeBSD/sys/dev/isci/scil/sci_abstract_list.c
/**
 * This method will simply search the supplied list for the desired object.
 * It will return a pointer to the abstract_list_element if found, otherwise
 * it will return NULL.
 */
This method will simply search the supplied list for the desired object.
It will return a pointer to the abstract_list_element if found, otherwise
it will return NULL.
This method will simply search the supplied list for the desired object . It will return a pointer to the abstract_list_element if found otherwise it will return NULL .
SCI_ABSTRACT_ELEMENT_T * private_find(
   SCI_ABSTRACT_ELEMENT_LIST_T * list_p,
   void * obj_p
)
{
   SCI_ABSTRACT_ELEMENT_T * alElement_p = (list_p)->front_p;
   while (alElement_p != NULL)
   {
      if (alElement_p->object_p == (void*) (obj_p))
      {
         break;
      }
      alElement_p = alElement_p->next_p;
   }
   return alElement_p;
}
SCI_ABSTRACT_ELEMENT_T * private_find ( SCI_ABSTRACT_ELEMENT_LIST_T * list_p , void * obj_p ) { SCI_ABSTRACT_ELEMENT_T * alElement_p = ( list_p ) -> front_p ; while ( alElement_p != NULL ) { if ( alElement_p -> object_p == ( void * ) ( obj_p ) ) { break ; } alElement_p = alElement_p -> next_p ; } return alElement_p ; }
This method will simply search the supplied list for the desired object.
This method will simply search the supplied list for the desired object .
/* Check to see if we found the object for which we are searching. */