aboutsummaryrefslogtreecommitdiffstats
path: root/libgamma_internal_parse_edid.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2021-03-05 00:43:38 +0100
committerMattias Andrée <maandree@kth.se>2021-03-05 00:43:38 +0100
commit0ce0d8d6e0c420ccafa79e0203b928c3559a4311 (patch)
tree88e8228a93691c28811a49898abf86a96dd9d613 /libgamma_internal_parse_edid.c
parentChange license + change style + misc (diff)
downloadlibgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.gz
libgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.bz2
libgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.xz
Split source files, merge public header files, eliminite use gpp, rewrite makefile
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--libgamma_internal_parse_edid.c (renamed from src/lib/edid.c)12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/lib/edid.c b/libgamma_internal_parse_edid.c
index fc7b498..aa1b87c 100644
--- a/src/lib/edid.c
+++ b/libgamma_internal_parse_edid.c
@@ -1,10 +1,5 @@
/* See LICENSE file for copyright and license details. */
-#include "edid.h"
-
-#include "libgamma-method.h"
-#include "libgamma-error.h"
-
-#include <stdint.h>
+#include "common.h"
/*
@@ -26,7 +21,7 @@
* @return Non-zero on error
*/
int
-libgamma_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields)
+libgamma_internal_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields)
{
#define __test_version(edid, major, minor_min, minor_max)\
((edid)[18] == (major) && (minor_min) <= (edid)[19] && (edid)[19] <= (minor_max))
@@ -79,10 +74,9 @@ libgamma_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields)
/* If not error has occurred, calculate and test the checksum.
It is not considered an error that the gamma characteristics
is left unspecified in the EDID. */
- if (!error) {
+ if (!error)
for (i = 0; i < this->edid_length; i++)
checksum += (int)this->edid[i];
- }
/* The checksum should be zero. */
if (checksum & 255) {
/* Store the error in all fields that require the EDID to be parsed,