From patchwork Wed May 3 03:52:08 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 98461 Delivered-To: patches@linaro.org Received: by 10.140.89.200 with SMTP id v66csp113102qgd; Tue, 2 May 2017 20:52:13 -0700 (PDT) X-Received: by 10.99.119.141 with SMTP id s135mr19303598pgc.133.1493783533076; Tue, 02 May 2017 20:52:13 -0700 (PDT) Return-Path: Received: from mail-pg0-x230.google.com (mail-pg0-x230.google.com. [2607:f8b0:400e:c05::230]) by mx.google.com with ESMTPS id d5si17248153pgn.47.2017.05.02.20.52.12 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 May 2017 20:52:12 -0700 (PDT) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 2607:f8b0:400e:c05::230 as permitted sender) client-ip=2607:f8b0:400e:c05::230; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org; spf=pass (google.com: domain of john.stultz@linaro.org designates 2607:f8b0:400e:c05::230 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by mail-pg0-x230.google.com with SMTP id v1so71359677pgv.1 for ; Tue, 02 May 2017 20:52:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=taq+4tVlOd+5u6uhw38xonTdwPshDlCOEBVYinzzpv8=; b=HhnVZV78K+Fpwmtub1Z78fkOv9voEmj9paJgrkFF1b5zQk5BjAzh5yERzXRHc0nGtO yQme3Tw9toihID9QkdUhW6jW0KHSWRhWqpXEwiDhf++7YhC0wdcUSCYk4CpN94M+bUmo pTmaiwaPSZkzYcjZXLpy4AQLpatlDRuFI+GZI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=taq+4tVlOd+5u6uhw38xonTdwPshDlCOEBVYinzzpv8=; b=ExUjIXbC3eZdYowYSgufyqZdeeLbfRnQgsQ9eqkl6C5ZPylGJG3eZ27PdZUv68gkFZ r3NoxwFPC2CBqwd4pSnBMIeSXYfUbxYJ35tkpFhCi+pOKYatxdd3+mhz+GlS2sSlHZYf JMLTWn6pT5s6auCzenJL3UOFzXI6r0FQQwtRPv1ZwZ3c9Q0/nrQTzODJKEVX0Qv38gja II0I2lLH3sXygPpr5GIRE+ZvoI8/yHzZx5duDXbz2EzGZLBjO6hqrOoPDrGVf9i2SG6Z lYmjZ+pQZlnhucs6z4V0WqxKzLhUudgteIoouwNqXGBGkMepGsnTWZXwx7W6FOtEp5z4 Pptg== X-Gm-Message-State: AN3rC/6Y3k97Cg2Altd0nbw7wP1x99BlnGKKF35TPbkUz19JUWKKDnBP 0pHzRAeZ0CAvcihFkiM= X-Received: by 10.99.109.9 with SMTP id i9mr11010612pgc.56.1493783532610; Tue, 02 May 2017 20:52:12 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([2601:1c2:1002:83f0:4e72:b9ff:fe99:466a]) by smtp.gmail.com with ESMTPSA id q87sm1409688pfj.112.2017.05.02.20.52.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 02 May 2017 20:52:11 -0700 (PDT) From: John Stultz To: Cc: John Stultz , Rob Herring , Sumit Semwal , Vishal Bhoj , Amit Pundir Subject: [PATCH v2] Add DPI override option Date: Tue, 2 May 2017 20:52:08 -0700 Message-Id: <1493783528-5436-1-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 2.7.4 This patch adds DPI override option and sets the db410c to 160. If the value is left at the default 0, it will be probed from the monitor. Cc: Rob Herring Cc: Sumit Semwal Cc: Vishal Bhoj Cc: Amit Pundir Signed-off-by: John Stultz --- configs/db410c_defconfig | 1 + graphics/Kconfig | 7 +++++++ graphics/device.mk | 3 +++ 3 files changed, 11 insertions(+) -- 2.7.4 diff --git a/configs/db410c_defconfig b/configs/db410c_defconfig index e13ad04..2254fcc 100644 --- a/configs/db410c_defconfig +++ b/configs/db410c_defconfig @@ -8,3 +8,4 @@ CONFIG_KERNEL_PATH="device/linaro/generic-kernels/android-db410c-qcomlt-4.9.gz-d CONFIG_BOARD_KERNEL_CMDLINE="androidboot.selinux=permissive firmware_class.path=/system/vendor/firmware/" CONFIG_BOARD_KERNEL_BASE=0x80008000 CONFIG_RAMDISK_OFFSET=0x0 +CONFIG_DISPLAY_DPI=160 diff --git a/graphics/Kconfig b/graphics/Kconfig index 6e76697..24d2255 100644 --- a/graphics/Kconfig +++ b/graphics/Kconfig @@ -32,4 +32,11 @@ config BOARD_GPU_DRIVERS default "freedreno virgl" endif +config DISPLAY_DPI + int "Display DPI setting override" + default 0 + help + Sets the DPI value. If left as zero, the DPI will + be probed via EDID from the monitor or use values + from DT. endmenu diff --git a/graphics/device.mk b/graphics/device.mk index bab2d62..267bc2f 100644 --- a/graphics/device.mk +++ b/graphics/device.mk @@ -3,6 +3,9 @@ PRODUCT_PROPERTY_OVERRIDES := $(if $(CONFIG_SW_GRAPHICS), \ PRODUCT_PACKAGES := libGLES_android +PRODUCT_PROPERTY_OVERRIDES += \ + ro.sf.lcd_density=$(CONFIG_DISPLAY_DPI) + subdirs-true := subdirs-$(BOARD_USES_DRM_HWCOMPOSER) += drm subdirs-$(CONFIG_GRALLOC_MALI) += gralloc