sdm: Populate supported format table map from sysfs node
1. Define default table map of supported format for all hw blocks.
2. Parse the sysfs node and populate supported format table map
information for all hw blocks.
Change-Id: I34404bb588ca00b9c9c5b58e7ee468bfca390e08
CRs-Fixed: 980862
diff --git a/sdm/include/utils/constants.h b/sdm/include/utils/constants.h
index 57c5a86..3185951 100644
--- a/sdm/include/utils/constants.h
+++ b/sdm/include/utils/constants.h
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2014 - 2015, The Linux Foundation. All rights reserved.
+* Copyright (c) 2014 - 2016, The Linux Foundation. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification, are permitted
* provided that the following conditions are met:
@@ -66,6 +66,9 @@
#define IS_RGB_FORMAT(format) (((format) < kFormatYCbCr420Planar) ? true: false)
+#define BITS_PER_BYTE 8
+#define BITS_TO_BYTES(x) (((x) + (BITS_PER_BYTE - 1)) / (BITS_PER_BYTE))
+
template <class T>
inline void Swap(T &a, T &b) {
T c(a);