Files
linux-nvgpu/drivers/gpu/nvgpu/hal/fb/fb_gp10b.c
Philip Elcan 012c8f983f gpu: nvgpu: fb: fix MISRA 10.3 violations
This fixes a number of MISRA Rule 10.3 violations for assignment of
objects of different essential type or size in the common/fb unit.

JIRA NVGPU-2954

Change-Id: I02e4e9a9789f355497900da2113d8f0c5a102336
Signed-off-by: Philip Elcan <pelcan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2075596
GVS: Gerrit_Virtual_Submit
Reviewed-by: Adeel Raza <araza@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2019-03-18 20:19:20 -07:00

39 lines
1.4 KiB
C

/*
* GP10B FB
*
* Copyright (c) 2014-2019, NVIDIA CORPORATION. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*/
#include <nvgpu/sizes.h>
#include <nvgpu/gk20a.h>
#include "fb_gp10b.h"
u64 gp10b_fb_compression_page_size(struct gk20a *g)
{
return SZ_64K;
}
unsigned int gp10b_fb_compressible_page_size(struct gk20a *g)
{
return (unsigned int)SZ_4K;
}