Firmware Update Backup via Bitwise XOR Grouping

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Firmware updates in user devices can result in data corruption due to power failures during the update process, especially when the file system cache is not flushed to non-volatile memory, leading to device inoperability and requiring frequent SYNC commands that decrease performance.

Innovation Solution

The method involves dividing modified files into groups, assigning offsets, and performing bitwise XOR operations between these groups and a backup buffer, storing the results in non-volatile storage as a backup file, which allows for reduced SYNC commands and efficient recovery from corrupted files.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If the file system cache is used to queue up changes before flushing to FLASH memory, then update performance is improved, but the risk of data corruption due to power failure increases

Engineering Contradiction:
Improveupdate performanceVSAvoiddata integrity
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent applies preliminary action by creating a backup file before the firmware update process begins. This backup file contains the original firmware data and serves as a safety net in case the update fails or power is lost during the process. The backup is prepared in advance, allowing the system to proceed with aggressive caching strategies while maintaining recovery capability.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent uses copying by creating a backup copy of the firmware data in a separate backup file stored in non-volatile memory. This copy is maintained independently from the cache operations, ensuring that even if the cache is lost due to power failure, the original firmware data can be restored from the backup copy.

Inventive Principle:
Principle #26Copying

2Reliability

If SYNC commands are frequently issued to flush cache to non-volatile memory, then data integrity is improved, but update performance deteriorates

Engineering Contradiction:
Improvedata integrityVSAvoidupdate performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent applies preliminary action by pre-allocating and preparing a backup file structure before the update process begins. This allows the system to defer synchronization operations until necessary, rather than requiring frequent SYNC commands during the update process. The backup file is ready to receive data at predefined offsets, enabling batch operations.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent applies segmentation by dividing the firmware update data into multiple groups, where each group is associated with a specific offset in the backup file. This segmentation allows the system to process and flush data in manageable chunks rather than requiring the entire cache to be synchronized at once, reducing the frequency and impact of SYNC commands.

Inventive Principle:
Principle #1Segmentation

3Productivity

If multiple files are modified before flushing to non-volatile memory, then update efficiency is improved, but the risk of corruption from power failure increases

Engineering Contradiction:
Improveupdate efficiencyVSAvoiddata integrity
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent applies segmentation by dividing modified files into multiple groups and assigning each group to a specific offset range in the backup file. This allows the system to track and manage multiple file modifications systematically, flushing groups to the backup file at controlled intervals rather than requiring immediate synchronization of every change.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent uses copying by maintaining the backup file as a separate copy of the firmware data structure. When files are modified in cache, the changes are eventually copied to the appropriate offsets in the backup file. This separate copy mechanism allows batch processing of multiple file modifications while preserving the ability to recover from power failures.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS9274900B2Method and apparatus for updating firmware
Publication Date: 2016.03.01 SAMSUNG ELECTRONICS CO LTD
  • US9274900B2 patent drawing
  • US9274900B2 patent drawing
  • US9274900B2 patent drawing

AI summary

A method for updating firmware in a user terminal comprises dividing files with modified contents into a plurality of groups and assigning each file with respective offset. The method then performs bitwise XOR operations between the plurality of groups onto the backup buffer. Consequently, the method stores a result of the bit XOR operations on the backup buffer into a non-volatile storage as a backup file. An apparatus for updating firmware comprises a processing circuit configured to divide files with modified contents into a plurality of groups and assign each file with respective offset. The processing circuit performs bitwise XOR operations between the plurality of groups onto the backup buffer and store a result of the bit XOR operations on the backup buffer into a non-volatile storage as a backup file.