gr2d.c (5acac83bf2e42f51ab9fd315d657798754bf0bb8) | gr2d.c (2aed4f5ab04af922a7cf1b616701845c9ed2473f) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (c) 2012-2013, NVIDIA Corporation. 4 */ 5 6#include <linux/clk.h> 7#include <linux/iommu.h> 8#include <linux/module.h> --- 53 unchanged lines hidden (view full) --- 62 goto detach; 63 } 64 65 return 0; 66 67detach: 68 host1x_client_iommu_detach(client); 69free: | 1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (c) 2012-2013, NVIDIA Corporation. 4 */ 5 6#include <linux/clk.h> 7#include <linux/iommu.h> 8#include <linux/module.h> --- 53 unchanged lines hidden (view full) --- 62 goto detach; 63 } 64 65 return 0; 66 67detach: 68 host1x_client_iommu_detach(client); 69free: |
70 host1x_syncpt_free(client->syncpts[0]); | 70 host1x_syncpt_put(client->syncpts[0]); |
71put: 72 host1x_channel_put(gr2d->channel); 73 return err; 74} 75 76static int gr2d_exit(struct host1x_client *client) 77{ 78 struct tegra_drm_client *drm = host1x_to_drm_client(client); 79 struct drm_device *dev = dev_get_drvdata(client->host); 80 struct tegra_drm *tegra = dev->dev_private; 81 struct gr2d *gr2d = to_gr2d(drm); 82 int err; 83 84 err = tegra_drm_unregister_client(tegra, drm); 85 if (err < 0) 86 return err; 87 88 host1x_client_iommu_detach(client); | 71put: 72 host1x_channel_put(gr2d->channel); 73 return err; 74} 75 76static int gr2d_exit(struct host1x_client *client) 77{ 78 struct tegra_drm_client *drm = host1x_to_drm_client(client); 79 struct drm_device *dev = dev_get_drvdata(client->host); 80 struct tegra_drm *tegra = dev->dev_private; 81 struct gr2d *gr2d = to_gr2d(drm); 82 int err; 83 84 err = tegra_drm_unregister_client(tegra, drm); 85 if (err < 0) 86 return err; 87 88 host1x_client_iommu_detach(client); |
89 host1x_syncpt_free(client->syncpts[0]); | 89 host1x_syncpt_put(client->syncpts[0]); |
90 host1x_channel_put(gr2d->channel); 91 92 return 0; 93} 94 95static const struct host1x_client_ops gr2d_client_ops = { 96 .init = gr2d_init, 97 .exit = gr2d_exit, --- 177 unchanged lines hidden --- | 90 host1x_channel_put(gr2d->channel); 91 92 return 0; 93} 94 95static const struct host1x_client_ops gr2d_client_ops = { 96 .init = gr2d_init, 97 .exit = gr2d_exit, --- 177 unchanged lines hidden --- |