Message ID | 20180129135513.22538-3-tom.stdenis@amd.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <dri-devel-bounces@lists.freedesktop.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A60DD6020C for <patchwork-dri-devel@patchwork.kernel.org>; Mon, 29 Jan 2018 13:55:34 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 89D5820121 for <patchwork-dri-devel@patchwork.kernel.org>; Mon, 29 Jan 2018 13:55:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7CDF920408; Mon, 29 Jan 2018 13:55:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED, RCVD_IN_SORBS_WEB, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 0591D20121 for <patchwork-dri-devel@patchwork.kernel.org>; Mon, 29 Jan 2018 13:55:33 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id ACBEF6E4A3; Mon, 29 Jan 2018 13:55:28 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0080.outbound.protection.outlook.com [104.47.38.80]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1C0546E4A8; Mon, 29 Jan 2018 13:55:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=afkojQMy7A8FVItzyl2+pHosJdp2aEMfwhT6QBgq+dA=; b=bVizUfHgR+ra/eNu/e7M8jTjSl7b/pWsqesFcu0zJiGjDMTk7TWlWY3ayjdl982y08HnZQNaMfW9UGv/abmuIScV2V45v6XjenV+24QSDiK701Wc/TeQUtOex2amlTGeQsA1geRiSoIdBAmJeCzHiytQQC4Av3DAb0bEBU8Bzgk= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Tom.StDenis@amd.com; Received: from fx8.amd.com (165.204.55.251) by DM5PR1201MB0075.namprd12.prod.outlook.com (10.174.106.17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.444.14; Mon, 29 Jan 2018 13:55:26 +0000 From: Tom St Denis <tom.stdenis@amd.com> To: amd-gfx@lists.freedesktop.org Subject: [PATCH 02/12] drm/ttm: Fix coding style in ttm_bo.c Date: Mon, 29 Jan 2018 08:55:03 -0500 Message-Id: <20180129135513.22538-3-tom.stdenis@amd.com> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180129135513.22538-1-tom.stdenis@amd.com> References: <20180129135513.22538-1-tom.stdenis@amd.com> MIME-Version: 1.0 X-Originating-IP: [165.204.55.251] X-ClientProxiedBy: CY4PR14CA0027.namprd14.prod.outlook.com (10.172.162.141) To DM5PR1201MB0075.namprd12.prod.outlook.com (10.174.106.17) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 5e52e716-57cd-457d-0643-08d5671ff3ab X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(4534165)(4627221)(201703031133081)(201702281549075)(48565401081)(5600026)(4604075)(2017052603307)(7153060)(7193020); SRVR:DM5PR1201MB0075; X-Microsoft-Exchange-Diagnostics: 1; DM5PR1201MB0075; 3:HuKorSLkvAA+RZ9qP87OtMEW0V4Lo3KnbrcCSmSECf+PUlTdAkR+86rVpfwPPoxsdXKrcwXTZe5UVgFvcuGEa9vbrDyoeoc5b92fJDh+7HMFGWAFFGgIKfVkdMbfrPJcl9B/qZtpfZhEDBhxlhi4SZ7G/NqDGLyIlcUY3My1jMOiJ7sGWCV8/767WKQs9YIahGnfAI8U6KXO49y3zfnvcMEvYmOvAIcxJ8f8lDmnfdxXfp3yNFW8jqQEkJBz38Eh; 25:fYvdYgFijdBySxkBZokiwoF6Y1MYIIGO1BFTE8O1Np2JXuJPRVIskZb+itwxZLe1HfGiZhBKYPP2u/Sh+33gFntSmye64vRpASxFM9NywrVOh7XQUYeSzT3uAK6d+6p6GSsXfyjbVTgzrdq/CbsZHiDf/WT7KthF2OYRaxty6KYGB1cOqSKuaTsdpXh1/Bx5yfjvQmcLLVnLobvd02MLxVjKwEAi2VOsMsu70leBPCSXM/z5buFEYvJLavgcL/p9YovF6d2REA/YuW5oMo71EPTKBTFaPxiXzZtyJFuMALVLL5ZP7S40vycHriTATXUZ3j063u8Z8NUx4EbkECQ2Aw==; 31:4oRTX70KDDT0Orz80HJjEEXlRrQaejAd4nCWkkDXiavobsDw6jPO26LJFIiX9X4PmQylp0aX1lFb0FNUMW75tt+L79zE1GuHRQ9e1Ze8cfKg9a7xGITkbOj6f2jy9FRvpXGslIJ+onhHIJvhHend8qCn3v8Dt84ebhrj8jTbXyccj45ChOI1GYQTH4L2rHdGPPK/bolOuOjPVHwd+iE6cjybn03Cvgmz3Mn5xmaWOhI= X-MS-TrafficTypeDiagnostic: DM5PR1201MB0075: X-Microsoft-Exchange-Diagnostics: 1; DM5PR1201MB0075; 20:kqgOD4XpxG4EM7JgKXMLWMJQJa93Wc5fKMuzd1sGOAOGVwM3te4OON3/hJaWJ2i3sElLyOAZCYb5p1st+u38hckIjreoSV0P3PjM5d966NCmGw6f8SFeC4RZPrFPH5Q8TM+895W8L30GLsFkaehI5LGbOZki/5Ne4empqNN8IymgZeyhWsuEHBSPmA0YCgKGe+UoqTfr02dzNQeU+pl8ImxkITez4YE4/hhPqd1xHq4PDbM1zjLBxf9rrp0smwt/AX41XK5brWHTnTbH6y+FBIh5ESTyo4wKP9dcKi2EeS14pa/vvIvjqgRECA1EhRijiy0Q+o800MieBWThZ3MBjgoOr9k8ipFocarsKoovnIvp152CWNjMsFyNLchrdfJi/cv1+ibVcQPZQrOiTTR43W5uQ8s5Kn+f/AXRCn9fJepqjsRb80Hp/fTTlu/r8tZi2Gmg3Guk7Xb34x+7KCiapXlEP0TCwQAZ/b6tytYHxidMEe1xgSru/kkkblM9lq7l; 4:6TYXpAVkI4fCDcu2m2h58ic2A3HLS0KO2IGpc+PauM3S+A2XKaNh5uHiJZgK/aBjKcUUmouxBdEp+DgxTa0ZRSULz9LETFlOno8WAp+xBxhnmzsHAinf/xxI4SvjSXwLn2a6sJ2ZOFZjaCuCtyyeZO+3QBeHOUPJj8ji78PmlJZVwdiOPQrLo3oTJeruCoamt+l6HBJXYGfBnU3gDGvXHV+MEscc/f27U1WrMeEXzmb+YcDr0fNOrDF6BN4ULECn0uHM6PBF0E6j6WRFPtBrxxQr0nrNO+J0tCJBgZoc1IWdl2i8Nk6Da3M3BQRT79Vn X-Microsoft-Antispam-PRVS: <DM5PR1201MB00754D0E9CE40C78F6859004F7E50@DM5PR1201MB0075.namprd12.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(5005006)(8121501046)(10201501046)(3002001)(3231101)(944501161)(93006095)(93001095)(6055026)(6041288)(20161123558120)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(20161123562045)(6072148)(201708071742011); SRVR:DM5PR1201MB0075; BCL:0; PCL:0; RULEID:; SRVR:DM5PR1201MB0075; X-Forefront-PRVS: 0567A15835 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(376002)(39380400002)(396003)(39860400002)(346002)(366004)(189003)(199004)(59450400001)(76176011)(478600001)(7696005)(450100002)(7736002)(52116002)(6486002)(23676004)(86362001)(305945005)(2870700001)(53936002)(66066001)(5660300001)(72206003)(47776003)(4326008)(386003)(81166006)(97736004)(2361001)(25786009)(2351001)(106356001)(316002)(6666003)(8936002)(2950100002)(16526019)(2906002)(81156014)(68736007)(6916009)(186003)(36756003)(105586002)(8676002)(53416004)(50226002)(1076002)(3846002)(6116002)(50466002)(26005); DIR:OUT; SFP:1101; SCL:1; SRVR:DM5PR1201MB0075; H:fx8.amd.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtETTVQUjEyMDFNQjAwNzU7MjM6U01FOGhFdFhuOGExZlJNSkQyUmZOT2lx?= =?utf-8?B?RFcrUmtBaDd5RXdnTG1sd05KaDRWc1FHdlByWStWem1yN3VaQU5LT0lVRUZG?= =?utf-8?B?dFYwYkFiUDhqUW5nakdic0VoNkRMVktVUW1lc0RHa1p3cFZna0xQQ28yditJ?= =?utf-8?B?eEFkZCtQdU9xSVFYOHhRMzVJeEZSVExVUDNFQ21ib1FwWE10WlZJdlo5ZE5r?= =?utf-8?B?bFl1WHVCRjJMZHJlUjZEd2dPcHVLWFVlUE9NNERPNGhyeThHc1Vmc3d6SFJ1?= =?utf-8?B?NE5BZGx4eGNSZmJDQlBLeFFNcysrY3ZXOHpHOVR1MzdPcGM2aHVZVGZKMkg5?= =?utf-8?B?dzZXQVVOblViY1BqSlllc24rNC9pdjNoRlh1WjhrWFZjUEZYcEd4WE5pZkIx?= =?utf-8?B?YTBGWS9jWFUya08vWFlONFhjRTRWdXdraHRKU0E0SVdGS3JSSVVHaHBLQUJ1?= =?utf-8?B?N3NEa0ZJ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JztSoVdpUrBPZf2b8r0+J1WA87AMyxIS3dfhfouusuQpsX5sMvzLvcWu+7LxbMJ3uwAeUqQ1NfcohewHvALAq/SMKPtojZob+/LAW7/EekfB0nBi0Jy9G1pK6qR4xgelDZDTgglSStsixxdZPbZUs0dCOk/vkcVXN7SI8jH2MN01V0cJ81ul9MzweRvhj21PQPYFlt/L SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DM5PR1201MB0075; 20:Ncg7OEP8wZ3hRR7Q+uSmKsiWWxJMLNlLDTKcmDHidQdjlvnoNcFgazLSK/cnlva9w9Ig9WDN74Wt2LxQcH1hlv3bnBCOTXf8O13EKadA9gMNPsAG7ZaOWUqIMiqSWsGHK5LKG1BMUHTCHft2TTD5qnHO8W4Vm2j2CUdE+Ur/tuJ13dLpnCV4/QJ5c/lkKNrM2FiJfma2vapS7FWx4RmZG/Vq5pNav4poWQbp/FLH1ENPNpEKvKL2JNnB17A6oIia X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Jan 2018 13:55:26.5949 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5e52e716-57cd-457d-0643-08d5671ff3ab X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR1201MB0075 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development <dri-devel.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/dri-devel> List-Post: <mailto:dri-devel@lists.freedesktop.org> List-Help: <mailto:dri-devel-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=subscribe> Cc: Tom St Denis <tom.stdenis@amd.com>, dri-devel@lists.freedesktop.org Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" <dri-devel-bounces@lists.freedesktop.org> X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index d33a6bb742a1..8cf89da7030d 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@ -149,9 +149,8 @@ static void ttm_bo_release_list(struct kref *list_kref) mutex_destroy(&bo->wu_mutex); if (bo->destroy) bo->destroy(bo); - else { + else kfree(bo); - } ttm_mem_global_free(bdev->glob->mem_glob, acc_size); } @@ -163,7 +162,6 @@ void ttm_bo_add_to_lru(struct ttm_buffer_object *bo) reservation_object_assert_held(bo->resv); if (!(bo->mem.placement & TTM_PL_FLAG_NO_EVICT)) { - BUG_ON(!list_empty(&bo->lru)); man = &bdev->man[bo->mem.mem_type]; @@ -614,10 +612,9 @@ static void ttm_bo_delayed_workqueue(struct work_struct *work) struct ttm_bo_device *bdev = container_of(work, struct ttm_bo_device, wq.work); - if (!ttm_bo_delayed_delete(bdev, false)) { + if (!ttm_bo_delayed_delete(bdev, false)) schedule_delayed_work(&bdev->wq, ((HZ / 100) < 1) ? 1 : HZ / 100); - } } static void ttm_bo_release(struct kref *kref)