blob: 9f21795437a674dae27ea13213afb4953c10e104 [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001// SPDX-License-Identifier: GPL-2.0+
Minkyu Kangc474a8e2010-05-31 22:02:42 +09002/*
3 * Copyright (C) 2008-2009 Samsung Electronics
4 * Kyungmin Park <kyungmin.park@samsung.com>
Minkyu Kangc474a8e2010-05-31 22:02:42 +09005 */
6
7#include <common.h>
8#include <linux/mtd/mtd.h>
9#include <linux/mtd/onenand.h>
10#include <linux/mtd/samsung_onenand.h>
11#include <onenand_uboot.h>
12
Ladislav Michl77b93e52016-07-12 20:28:20 +020013int onenand_board_init(struct mtd_info *mtd)
Minkyu Kangc474a8e2010-05-31 22:02:42 +090014{
15 struct onenand_chip *this = mtd->priv;
16
17 this->base = (void *)CONFIG_SYS_ONENAND_BASE;
18 this->options |= ONENAND_RUNTIME_BADBLOCK_CHECK;
Lukasz Majewski8f9c2492011-11-09 11:27:14 +010019 this->chip_probe = s5pc110_chip_probe;
Ladislav Michl77b93e52016-07-12 20:28:20 +020020
21 return 0;
Minkyu Kangc474a8e2010-05-31 22:02:42 +090022}