From 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e Mon Sep 17 00:00:00 2001 From: hc <hc@nodka.com> Date: Mon, 13 May 2024 10:30:14 +0000 Subject: [PATCH] modify sin led gpio --- kernel/drivers/vfio/platform/vfio_amba.c | 25 ++++++------------------- 1 files changed, 6 insertions(+), 19 deletions(-) diff --git a/kernel/drivers/vfio/platform/vfio_amba.c b/kernel/drivers/vfio/platform/vfio_amba.c index 62dfbfe..3626c21 100644 --- a/kernel/drivers/vfio/platform/vfio_amba.c +++ b/kernel/drivers/vfio/platform/vfio_amba.c @@ -1,15 +1,7 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * Copyright (C) 2013 - Virtual Open Systems * Author: Antonios Motakis <a.motakis@virtualopensystems.com> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License, version 2, as - * published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. */ #include <linux/module.h> @@ -79,18 +71,13 @@ return ret; } -static int vfio_amba_remove(struct amba_device *adev) +static void vfio_amba_remove(struct amba_device *adev) { - struct vfio_platform_device *vdev; + struct vfio_platform_device *vdev = + vfio_platform_remove_common(&adev->dev); - vdev = vfio_platform_remove_common(&adev->dev); - if (vdev) { - kfree(vdev->name); - kfree(vdev); - return 0; - } - - return -EINVAL; + kfree(vdev->name); + kfree(vdev); } static const struct amba_id pl330_ids[] = { -- Gitblit v1.6.2