| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Frame buffer device for IBM GXT4500P/6500P and GXT4000P/6000P |
|---|
| 3 | 4 | * display adaptors |
|---|
| .. | .. |
|---|
| 533 | 534 | break; |
|---|
| 534 | 535 | case DFA_PIX_32BIT: |
|---|
| 535 | 536 | val |= (reg << 24); |
|---|
| 536 | | - /* fall through */ |
|---|
| 537 | + fallthrough; |
|---|
| 537 | 538 | case DFA_PIX_24BIT: |
|---|
| 538 | 539 | val |= (reg << 16) | (reg << 8); |
|---|
| 539 | 540 | break; |
|---|
| .. | .. |
|---|
| 598 | 599 | .mmio_len = 0x20000, |
|---|
| 599 | 600 | }; |
|---|
| 600 | 601 | |
|---|
| 601 | | -static struct fb_ops gxt4500_ops = { |
|---|
| 602 | +static const struct fb_ops gxt4500_ops = { |
|---|
| 602 | 603 | .owner = THIS_MODULE, |
|---|
| 603 | 604 | .fb_check_var = gxt4500_check_var, |
|---|
| 604 | 605 | .fb_set_par = gxt4500_set_par, |
|---|
| .. | .. |
|---|
| 642 | 643 | } |
|---|
| 643 | 644 | |
|---|
| 644 | 645 | info = framebuffer_alloc(sizeof(struct gxt4500_par), &pdev->dev); |
|---|
| 645 | | - if (!info) { |
|---|
| 646 | | - dev_err(&pdev->dev, "gxt4500: cannot alloc FB info record\n"); |
|---|
| 646 | + if (!info) |
|---|
| 647 | 647 | goto err_free_fb; |
|---|
| 648 | | - } |
|---|
| 648 | + |
|---|
| 649 | 649 | par = info->par; |
|---|
| 650 | 650 | cardtype = ent->driver_data; |
|---|
| 651 | 651 | par->refclk_ps = cardinfo[cardtype].refclk_ps; |
|---|