Skip to content

Commit

Permalink
platform/x86/intel: tpmi: Revise the comment of intel_vsec_add_aux
Browse files Browse the repository at this point in the history
intel_vsec_add_aux() is resource managed including res and
feature_vsec_dev memory.

Fix this by revising the comment of intel_vsec_add_aux since res variable
will also be freed in the intel_vsec_add_aux.

Signed-off-by: Dongliang Mu <dzm91@hust.edu.cn>
Link: https://lore.kernel.org/r/20230309040107.534716-3-dzm91@hust.edu.cn
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
  • Loading branch information
Dongliang Mu authored and Hans de Goede committed Mar 20, 2023
1 parent 4d5a2a7 commit 8d13d50
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/platform/x86/intel/tpmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,8 @@ static int tpmi_create_device(struct intel_tpmi_info *tpmi_info,
/*
* intel_vsec_add_aux() is resource managed, no explicit
* delete is required on error or on module unload.
* feature_vsec_dev memory is also freed as part of device
* delete.
* feature_vsec_dev and res memory are also freed as part of
* device deletion.
*/
return intel_vsec_add_aux(vsec_dev->pcidev, &vsec_dev->auxdev.dev,
feature_vsec_dev, feature_id_name);
Expand Down

0 comments on commit 8d13d50

Please sign in to comment.