Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\debugobjects.c Create Date:2022-07-28 06:55:12
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:debug_object_deactivate - debug checks when an object is deactivated*@addr: address of the object*@descr: pointer to an object specific debug description structure

Proto:void debug_object_deactivate(void *addr, struct debug_obj_descr *descr)

Type:void

Parameter:

TypeParameterName
void *addr
struct debug_obj_descr *descr
703  bool print_object = false
705  If Not debug_objects_enabled Then Return
708  db = We use the pfn of the address for the hash. That way we can check* for freed objects simply by checking the affected bucket.
710  raw_spin_lock_irqsave( & lock, flags)
712  obj = Lookup an object in the hash bucket.
713  If obj Then
715  Case state == ODEBUG_STATE_INIT
716  Case state == ODEBUG_STATE_INACTIVE
717  Case state == ODEBUG_STATE_ACTIVE
718  If Not astate Then state = ODEBUG_STATE_INACTIVE
720  Else print_object = true
722  Break
725  print_object = true
726  Break
727  Default
728  Break
732  raw_spin_unlock_irqrestore( & lock, flags)
733  If Not obj Then
734  struct debug_obj o = {object = addr, state = ODEBUG_STATE_NOTAVAILABLE, descr = descr}
738  debug_print_object( & o, "deactivate")
739  Else if print_object Then
740  debug_print_object(obj, "deactivate")