| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Copyright 2012 Freescale Semiconductor, Inc. |
|---|
| 3 | 4 | * Copyright 2012 Linaro Ltd. |
|---|
| 4 | | - * |
|---|
| 5 | | - * The code contained herein is licensed under the GNU General Public |
|---|
| 6 | | - * License. You may obtain a copy of the GNU General Public License |
|---|
| 7 | | - * Version 2 or later at the following locations: |
|---|
| 8 | | - * |
|---|
| 9 | | - * http://www.opensource.org/licenses/gpl-license.html |
|---|
| 10 | | - * http://www.gnu.org/copyleft/gpl.html |
|---|
| 11 | 5 | */ |
|---|
| 12 | 6 | |
|---|
| 13 | 7 | #include <linux/clk.h> |
|---|
| .. | .. |
|---|
| 393 | 387 | |
|---|
| 394 | 388 | root = of_find_node_by_path("/"); |
|---|
| 395 | 389 | ret = of_property_read_string(root, "model", &soc_dev_attr->machine); |
|---|
| 396 | | - if (ret) |
|---|
| 390 | + if (ret) { |
|---|
| 391 | + kfree(soc_dev_attr); |
|---|
| 397 | 392 | return; |
|---|
| 393 | + } |
|---|
| 398 | 394 | |
|---|
| 399 | 395 | soc_dev_attr->family = "Freescale MXS Family"; |
|---|
| 400 | 396 | soc_dev_attr->soc_id = mxs_get_soc_id(); |
|---|