Skip to content
This repository was archived by the owner on Jan 23, 2026. It is now read-only.

add support for RcarS4#506

Merged
mangelajo merged 3 commits intojumpstarter-dev:mainfrom
bennyz:rcars4
Jun 3, 2025
Merged

add support for RcarS4#506
mangelajo merged 3 commits intojumpstarter-dev:mainfrom
bennyz:rcars4

Conversation

@bennyz
Copy link
Copy Markdown
Member

@bennyz bennyz commented May 28, 2025

Add support for RCar S4 in the generic flashers driver

Summary by CodeRabbit

  • New Features

    • Added support for the Renesas R-Car S4 platform, including a new manifest, a dedicated flasher driver, and a large binary flasher file managed via Git LFS.
    • Introduced a command-line interface for GPIO power control in the Raspberry Pi driver.
  • Improvements

    • Enhanced flasher bundle handling to allow for optional device tree blob (DTB) files with null-safety checks.
    • Updated environment variable exports during the flashing process for better session configuration.
  • Dependency Updates

    • Added the click library and jumpstarter-driver-power as dependencies for the Raspberry Pi driver.

@bennyz bennyz requested review from Copilot and mangelajo May 28, 2025 15:50
@netlify
Copy link
Copy Markdown

netlify Bot commented May 28, 2025

Deploy Preview for jumpstarter-docs ready!

Name Link
🔨 Latest commit 02c9bc6
🔍 Latest deploy log https://app.netlify.com/projects/jumpstarter-docs/deploys/683eb3a3eba9fb0008ac6d91
😎 Deploy Preview https://deploy-preview-506--jumpstarter-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 28, 2025

"""

Walkthrough

This update introduces support for the Renesas R-Car S4 platform in the flasher driver system, including a new manifest, a dedicated flasher subclass, and Git LFS configuration for large files. Additionally, it refactors the Raspberry Pi digital output client to inherit from a power control base class and enhances its CLI integration. The flasher bundle manifest and driver logic were updated to handle optional device tree blobs.

Changes

File(s) Change Summary
.gitattributes Added Git LFS configuration for RCar S4 flasher bundle data files.
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py Exported DHCP and gateway addresses to busybox console session; adjusted timeout formatting in expect calls.
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py Added RCarS4Flasher subclass; modified setup_flasher_bundle to conditionally handle optional DTB files.
packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml Added manifest defining boot, network, and image details for RCar S4 platform.
packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py Changed DigitalOutputClient base class to PowerClient; reordered methods; added CLI group command.
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py Made dtb attribute optional in manifest spec; updated methods to handle missing DTB safely.
packages/jumpstarter-driver-raspberrypi/pyproject.toml Added click dependency with minimum version 8.1.7.2 and jumpstarter-driver-power dependency.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant DigitalOutputClient
    participant PowerClient
    participant CLI

    User->>DigitalOutputClient: Invoke cli()
    DigitalOutputClient->>PowerClient: Retrieve superclass CLI commands
    DigitalOutputClient->>CLI: Add commands to 'gpio' command group
    CLI-->>User: Present GPIO power control commands
Loading
sequenceDiagram
    participant System
    participant RCarS4Flasher
    participant FlashBundleManifest

    System->>RCarS4Flasher: Initialize flasher instance
    RCarS4Flasher->>FlashBundleManifest: Access 'rcar-s4' manifest and bundle info
    FlashBundleManifest-->>RCarS4Flasher: Provide boot commands, device info, and image paths
    RCarS4Flasher-->>System: Ready to perform flashing operations
Loading

Possibly related PRs

Suggested reviewers

  • mangelajo

Poem

In the land of code where drivers grow,
A new R-Car S4 flasher joins the show!
With manifests and bundles, Git LFS in tow,
Raspberry Pi’s power gets a CLI glow.
Hopping forward, features anew,
This rabbit cheers the work you do! 🐇✨
"""

✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Comment thread .gitattributes Outdated
class RCarS4Flasher(BaseFlasher):
""" RCarS4 driver for Jumpstarter"""

flasher_bundle: str = "quay.io/bzlotnik/jumpstarter-flasher-rcars4:latest"
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change before merging

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
flasher_bundle: str = "quay.io/bzlotnik/jumpstarter-flasher-rcars4:latest"
flasher_bundle: str = "quay.io/jumpstarter-dev/jumpstarter-flasher-rcars4:latest"

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds support for the Renesas RCarS4 flash bundle and improves the Raspberry Pi GPIO power client interface.

  • Refactor DigitalOutputClient to extend PowerClient, expose on/off methods, and add a combined CLI group
  • Introduce a new FlashBundleManifest for RCarS4 and register it in LFS
  • Add RCarS4Flasher driver class and inject DHCP/gateway exports in the flash client

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py Use PowerClient, add on/off methods, override cli() to group GPIO commands
packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml New manifest for RCarS4 flash bundle
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py Define RCarS4Flasher with its container image
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py Export dhcp_addr & gw_addr before running preflash commands
.gitattributes Mark RCarS4 bundle data for Git LFS
Comments suppressed due to low confidence (2)

packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py:17

  • The indentation of this line appears misaligned with its method block; ensure it is indented consistently.
        self.call("off")

packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py:206

  • There are no tests covering the new RCarS4Flasher; consider adding unit or integration tests to verify its behavior.
class RCarS4Flasher(BaseFlasher):

Comment thread packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml Outdated
Comment thread packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (6)
.gitattributes (1)

1-1: LGTM - Git LFS configuration is appropriate for binary data files.

The Git LFS configuration follows standard practices for managing large binary files. However, based on the past review comment, please remember to remove the artifacts as planned.

packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py (2)

10-17: Consider adding return type annotations for consistency.

The methods on() and off() should include return type annotations (-> None) to maintain consistency with other client methods, as suggested in previous reviews.

-    def on(self):
+    def on(self) -> None:
         """Turn power on"""
         self.call("on")

-    def off(self):
+    def off(self) -> None:
         """Turn power off"""
         self.call("off")

19-28: Consider adding docstring and return type annotation to CLI method.

As noted in previous reviews, public CLI entry points should include a docstring and return type annotation.

-    def cli(self):
+    def cli(self):
+        """
+        Create and return a click command group for GPIO power control commands.
+
+        Returns:
+            click.Group: A command group containing GPIO power control commands.
+        """
         @click.group()
         def gpio():
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py (1)

127-130: LGTM - Environment variable exports enhance flash process.

The addition of dhcp_addr and gw_addr environment variables will provide valuable network configuration to the flashing environment. The implementation correctly follows the existing pattern.

Consider consolidating export and expect calls to reduce duplication.

As suggested in previous reviews, these export and expect calls could be consolidated into a loop or helper function.

-                console.sendline(f"export dhcp_addr={self._dhcp_details.ip_address}")
-                console.expect(manifest.spec.login.prompt, timeout=EXPECT_TIMEOUT_DEFAULT)
-                console.sendline(f"export gw_addr={self._dhcp_details.gateway}")
-                console.expect(manifest.spec.login.prompt, timeout=EXPECT_TIMEOUT_DEFAULT)
+                for var_name, value in [("dhcp_addr", self._dhcp_details.ip_address), ("gw_addr", self._dhcp_details.gateway)]:
+                    console.sendline(f"export {var_name}={value}")
+                    console.expect(manifest.spec.login.prompt, timeout=EXPECT_TIMEOUT_DEFAULT)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)

205-210: Address the "change before merging" comment and formatting issues.

There's a past review comment from the author (bennyz) on line 210 stating "change before merging". Please clarify what needs to be changed before this can be merged.

Additionally, previous reviews suggested adding a blank line before the class declaration for PEP8 compliance.

 class TIJ784S4Flasher(BaseFlasher):
     """driver for Jumpstarter"""

     flasher_bundle: str = "quay.io/jumpstarter-dev/jumpstarter-flasher-ti-j784s4:latest"
+

 class RCarS4Flasher(BaseFlasher):
packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml (1)

10-12: Duplicate: Empty login_prompt field
The login_prompt is set to an empty string while prompt is defined. Consider removing or clarifying the purpose of login_prompt.

🧹 Nitpick comments (1)
packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml (1)

26-30: Consider quoting DTB variant names
While YAML allows unquoted keys with hyphens, quoting "r8a779f0-spider" for both default and the variant key can improve readability and avoid parsing edge cases.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9a72726 and 5654634.

📒 Files selected for processing (5)
  • .gitattributes (1 hunks)
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py (3 hunks)
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1 hunks)
  • packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml (1 hunks)
  • packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py (1)
examples/soc-pytest/jumpstarter_example_soc_pytest/test_on_rpi4.py (1)
  • console (20-24)
🪛 GitHub Actions: Run Tests
packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py

[error] 3-3: ModuleNotFoundError: No module named 'click' - Import failed during test collection.

⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: e2e
🔇 Additional comments (10)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)

207-210: LGTM - RCarS4Flasher implementation follows established pattern.

The RCarS4Flasher class correctly inherits from BaseFlasher and sets the appropriate container image for the R-Car S4 platform. The implementation is consistent with the existing TIJ784S4Flasher class.

packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml (9)

1-2: Check CRD compatibility
Ensure that the FlashBundleManifest resource kind and API version jumpstarter.dev/v1alpha1 are supported by the cluster or tooling consuming this manifest.


3-5: Validate metadata naming convention
The resource name rcar-s4 follows DNS-1123 label rules and clearly identifies the platform. No changes needed here.


6-7: Review manufacturer and link fields
The manufacturer is correctly set to "Renesas". Please verify that the link URL is accurate and reachable, as it will be surfaced in the UI or documentation.


8-8: Verify boot command addresses
Confirm that the memory load addresses (0x58000000, 0x48080000, 0x48000000) in bootcmd align with the R-Car S4 boot requirements and match the addresses used in the flasher driver.


9-9: Confirm shelltype support
Ensure that the chosen busybox shell image in the flasher bundle includes the necessary networking and filesystem commands used in preflash_commands.


13-15: Default target mapping is correct
The default_target of "emmc" matches the key under targets. The device path /dev/mmcblk0 looks correct for R-Car S4 eMMC.


16-19: Ensure environment variables for networking
preflash_commands reference ${dhcp_addr} and ${gw_addr}: verify that these are exported by the flasher client before this manifest is applied, and consider adding error handling or idempotency checks if the commands fail.


20-22: Verify kernel artifact path
Confirm that data/kernel exists in the OCI bundle image and points to the correct R-Car S4 kernel binary.


23-25: Verify initramfs artifact path
Ensure data/initramfs is included in the bundle and corresponds to the correct initramfs for R-Car S4.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5654634 and 98109c9.

📒 Files selected for processing (3)
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py (2 hunks)
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (2 hunks)
  • packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py
🧰 Additional context used
🧬 Code Graph Analysis (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)
  • get_dtb_address (183-186)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: e2e
🔇 Additional comments (3)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py (3)

36-36: LGTM! Correctly implements optional DTB support.

Making the dtb field optional with a proper default value enables support for platforms that don't require device tree blobs, aligning with the RcarS4 platform requirements.


56-58: LGTM! Proper null safety implementation.

The null check correctly handles the optional DTB case and maintains consistency with the get_dtb_address method. Since the return type was already str | None, this change doesn't introduce breaking compatibility issues.


36-36: Well-designed implementation following existing patterns.

The changes consistently implement optional DTB support by following the same pattern used for the optional initram field. The implementation is clean, focused, and maintains consistency across all DTB-related methods.

Also applies to: 50-53, 56-58

Comment on lines +50 to 53
def get_dtb_address(self) -> str | None:
if not self.spec.dtb:
return None
return self.spec.dtb.address
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Verify compatibility with existing callers.

The implementation correctly handles optional DTB with proper null checks. However, the return type change from str to str | None could break existing code.

From the relevant code snippet, driver.py line 186 shows a method that calls get_dtb_address() but still declares a str return type, creating a type mismatch.


🏁 Script executed:

#!/bin/bash
# Description: Find all callers of get_dtb_address to verify they handle None returns
# Expected: All callers should handle the new Optional return type

echo "=== Searching for get_dtb_address method calls ==="
rg -A 3 -B 1 "get_dtb_address\(\)" --type py

echo -e "\n=== Searching for get_dtb_address method definitions ==="
ast-grep --pattern 'def get_dtb_address($_) -> $ret_type:
  $$$'

Length of output: 1526


Handle Optional return of get_dtb_address in all callers

The change to return str | None from get_dtb_address introduces a breaking change: existing callers assume a non‐null string and will crash or misbehave if they receive None.

Please update the following locations:

  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py
    At the call in your get_kernel_address method (return manifest.get_dtb_address() around line 186):
    • Either guard against None before returning (and adjust the return type to str | None),
    • Or ensure dtb is always present so that a str is guaranteed.

  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py
    At the lines using dtb_address = manifest.get_dtb_address() followed by tftpboot {dtb_address} …:
    • Add a check for None and handle the absence of a DTB (e.g., throw a descriptive error or skip the tftpboot step).

Making these updates will restore type safety and prevent runtime failures when dtb is undefined.

🤖 Prompt for AI Agents
In packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py
lines 50 to 53, the method get_dtb_address now returns str | None, which breaks
callers expecting only str. Update all callers accordingly: in driver.py around
line 186, modify get_kernel_address to handle the None case by either changing
its return type to str | None or ensuring dtb is always present; in client.py,
add checks after calling get_dtb_address to handle None safely, such as raising
an error or skipping tftpboot steps. These changes will maintain type safety and
prevent runtime errors.

@mangelajo
Copy link
Copy Markdown
Member

You need to add "click" to the pyproject of the rpi driver.

@mangelajo
Copy link
Copy Markdown
Member

@bennyz ^ otherwise it won't install the dependency and fail the unit tests.

@bennyz bennyz force-pushed the rcars4 branch 2 times, most recently from 4cb657c to 737b27b Compare May 29, 2025 16:59
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds support for the Renesas R-Car S4 platform and enhances the Raspberry Pi driver with GPIO power controls.

  • Introduce a new RCarS4Flasher and its OCI manifest
  • Extend Raspberry Pi DigitalOutputClient to use PowerClient with click-based CLI
  • Make DTB handling optional and update dependencies for power control

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/jumpstarter-driver-raspberrypi/pyproject.toml Added jumpstarter-driver-power and click dependencies for GPIO power CLI
packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py Switched DigitalOutputClient to inherit from PowerClient, added on/off methods and CLI group
packages/jumpstarter-driver-flashers/oci_bundles/rcar_s4/manifest.yaml Added R-Car S4 flash bundle manifest
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py Guard DTB setup on spec.dtb, added new RCarS4Flasher class
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/client.py Exported dhcp_addr and gw_addr before flash
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/bundle.py Changed dtb to Optional[DtbVariant] and updated get_dtb_* methods
.gitattributes Enabled Git LFS for R-Car S4 data
Comments suppressed due to low confidence (2)

packages/jumpstarter-driver-raspberrypi/jumpstarter_driver_raspberrypi/client.py:20

  • [nitpick] The CLI group is named gpio but manages power commands; consider renaming it to power for clarity.
@click.group()
        def gpio():

packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py:209

  • No tests appear to cover the new RCarS4Flasher; consider adding unit or integration tests to validate its behavior.
class RCarS4Flasher(BaseFlasher):

Copy link
Copy Markdown
Member

@mangelajo mangelajo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We only need to change the image ref, and publish it.

@bennyz bennyz force-pushed the rcars4 branch 2 times, most recently from ac301f1 to 72e5de2 Compare May 30, 2025 09:09
@bennyz
Copy link
Copy Markdown
Member Author

bennyz commented May 30, 2025

bundle published

follow ups:

  1. make network config optional
  2. use the adafruit lib for gpio
  3. instructions for bundle

emmc: "/dev/mmcblk0"
kernel:
file: data/flasher.itb
address: "0x58000000"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: this is the address bootm uses by deafult, but if you change that (for other boards perhaps) then "bootm" without argumetns won't work. so maybe make it more explicit setting bootcmd to "bootm $0x58000000"

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume it's bootm 0x58000000 or bootm $loadddr

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

per doc without an argument is uses the last tftpboot loaded address. so it's fine as is, though it depends on the order of loading things

bennyz added 2 commits May 30, 2025 21:16
Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
@mangelajo mangelajo enabled auto-merge June 3, 2025 08:34
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

♻️ Duplicate comments (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)

208-212: Verify flasher bundle URL naming convention.

The new RCarS4Flasher class follows the correct pattern and successfully adds support for RCar S4 as intended. However, there's an inconsistency in the flasher bundle URL naming.

Based on previous review feedback, consider using consistent naming:

-    flasher_bundle: str = "quay.io/jumpstarter-dev/jumpstarter-flasher-rcar-s4:latest"
+    flasher_bundle: str = "quay.io/jumpstarter-dev/jumpstarter-flasher-rcars4:latest"

Note: The static analysis warnings about abstract methods are false positives since the base class methods use raise NotImplementedError pattern rather than @abstractmethod decorator, and the existing TIJ784S4Flasher class follows the same pattern.

🧰 Tools
🪛 Pylint (3.3.7)

[warning] 209-209: Method 'set_dtb' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)


[warning] 209-209: Method 'set_initram' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)


[warning] 209-209: Method 'set_kernel' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)

🧹 Nitpick comments (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)

87-90: Approve DTB conditional handling with minor style improvement.

The conditional logic correctly handles optional DTB files as intended. However, the line is quite long and could be simplified as suggested in previous reviews.

Consider this simpler approach to address the line length warning:

-        dtb_path = await self._get_file_path(manifest.get_dtb_file(self._use_dtb)) if manifest.spec.dtb else None
+        dtb_file = manifest.get_dtb_file(self._use_dtb) if manifest.spec.dtb else None
+        dtb_path = await self._get_file_path(dtb_file) if dtb_file else None
🧰 Tools
🪛 Pylint (3.3.7)

[convention] 87-87: Line too long (113/100)

(C0301)

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4936fd3 and 02c9bc6.

📒 Files selected for processing (1)
  • packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (2 hunks)
🧰 Additional context used
🪛 Pylint (3.3.7)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py

[convention] 87-87: Line too long (113/100)

(C0301)


[warning] 209-209: Method 'set_dtb' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)


[warning] 209-209: Method 'set_initram' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)


[warning] 209-209: Method 'set_kernel' is abstract in class 'BaseFlasher' but is not overridden in child class 'RCarS4Flasher'

(W0223)

⏰ Context from checks skipped due to timeout of 90000ms (6)
  • GitHub Check: e2e
  • GitHub Check: pytest-matrix (ubuntu-24.04, 3.12)
  • GitHub Check: pytest-matrix (macos-15, 3.12)
  • GitHub Check: pytest-matrix (macos-15, 3.11)
  • GitHub Check: pytest-matrix (ubuntu-24.04, 3.11)
  • GitHub Check: pytest-matrix (ubuntu-24.04, 3.13)
🔇 Additional comments (1)
packages/jumpstarter-driver-flashers/jumpstarter_driver_flashers/driver.py (1)

206-206: LGTM! PEP8 compliance improvement.

The blank line addition improves code formatting and addresses previous review feedback.

@mangelajo mangelajo merged commit 3d2ae4c into jumpstarter-dev:main Jun 3, 2025
18 checks passed
@bennyz bennyz deleted the rcars4 branch June 3, 2025 08:49
@coderabbitai coderabbitai Bot mentioned this pull request Jun 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants