Browse Source

Revert errant const

Scott Lahteine 5 years ago
parent
commit
f2d93f61c3

+ 1
- 1
Marlin/src/HAL/HAL_DUE/persistent_store_eeprom.cpp View File

@@ -44,7 +44,7 @@ bool PersistentStore::access_finish() {
44 44
   return true;
45 45
 }
46 46
 
47
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
47
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
48 48
   while (size--) {
49 49
     uint8_t * const p = (uint8_t * const)pos;
50 50
     uint8_t v = *value;

+ 1
- 1
Marlin/src/HAL/HAL_ESP32/persistent_store_spiffs.cpp View File

@@ -72,7 +72,7 @@ bool PersistentStore::access_finish() {
72 72
   return true;
73 73
 }
74 74
 
75
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
75
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
76 76
   if (!eeprom_file.seek(pos)) return true; // return true for any error
77 77
   if (eeprom_file.write(value, size) != size) return true;
78 78
 

+ 1
- 1
Marlin/src/HAL/HAL_LPC1768/persistent_store_flash.cpp View File

@@ -109,7 +109,7 @@ bool PersistentStore::access_finish() {
109 109
   return true;
110 110
 }
111 111
 
112
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
112
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
113 113
   for (size_t i = 0; i < size; i++) ram_eeprom[pos + i] = value[i];
114 114
   eeprom_dirty = true;
115 115
   crc16(crc, value, size);

+ 1
- 1
Marlin/src/HAL/HAL_SAMD51/persistent_store_eeprom.cpp View File

@@ -58,7 +58,7 @@ bool PersistentStore::access_finish() {
58 58
   return true;
59 59
 }
60 60
 
61
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
61
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
62 62
   #if NONE(SPI_EEPROM, I2C_EEPROM)
63 63
     if (NVMCTRL->SEESTAT.bit.RLOCK)
64 64
       NVMCTRL_CMD(NVMCTRL_CTRLB_CMD_USEE);    // Unlock E2P data write access

+ 1
- 1
Marlin/src/HAL/HAL_STM32/persistent_store_impl.cpp View File

@@ -50,7 +50,7 @@ bool PersistentStore::access_finish() {
50 50
   return true;
51 51
 }
52 52
 
53
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
53
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
54 54
   while (size--) {
55 55
     uint8_t v = *value;
56 56
 

+ 1
- 1
Marlin/src/HAL/HAL_STM32F1/persistent_store_eeprom.cpp View File

@@ -40,7 +40,7 @@ bool PersistentStore::access_start() {
40 40
 }
41 41
 bool PersistentStore::access_finish() { return true; }
42 42
 
43
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
43
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
44 44
   while (size--) {
45 45
     uint8_t * const p = (uint8_t * const)pos;
46 46
     uint8_t v = *value;

+ 1
- 1
Marlin/src/HAL/HAL_STM32_F4_F7/persistent_store_eeprom.cpp View File

@@ -32,7 +32,7 @@
32 32
 bool PersistentStore::access_start() { return true; }
33 33
 bool PersistentStore::access_finish() { return true; }
34 34
 
35
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
35
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
36 36
   while (size--) {
37 37
     uint8_t * const p = (uint8_t * const)pos;
38 38
     uint8_t v = *value;

+ 1
- 1
Marlin/src/HAL/HAL_TEENSY31_32/persistent_store_impl.cpp View File

@@ -27,7 +27,7 @@
27 27
 bool PersistentStore::access_start() { return true; }
28 28
 bool PersistentStore::access_finish() { return true; }
29 29
 
30
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
30
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
31 31
   while (size--) {
32 32
     uint8_t * const p = (uint8_t * const)pos;
33 33
     uint8_t v = *value;

+ 1
- 1
Marlin/src/HAL/HAL_TEENSY35_36/persistent_store_eeprom.cpp View File

@@ -33,7 +33,7 @@
33 33
 bool PersistentStore::access_start() { return true; }
34 34
 bool PersistentStore::access_finish() { return true; }
35 35
 
36
-bool PersistentStore::write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc) {
36
+bool PersistentStore::write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc) {
37 37
   while (size--) {
38 38
     uint8_t * const p = (uint8_t * const)pos;
39 39
     uint8_t v = *value;

+ 1
- 1
Marlin/src/HAL/shared/persistent_store_api.h View File

@@ -31,7 +31,7 @@ class PersistentStore {
31 31
 public:
32 32
   static bool access_start();
33 33
   static bool access_finish();
34
-  static bool write_data(int &pos, const uint8_t *value, const size_t size, uint16_t *crc);
34
+  static bool write_data(int &pos, const uint8_t *value, size_t size, uint16_t *crc);
35 35
   static bool read_data(int &pos, uint8_t* value, size_t size, uint16_t *crc, const bool writing=true);
36 36
   static size_t capacity();
37 37
 

Loading…
Cancel
Save