Make the floppy driver buildable again... even under Haiku.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26050 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,32 +1,12 @@
|
|||||||
SubDir HAIKU_TOP src add-ons kernel drivers arch x86 floppy ;
|
SubDir HAIKU_TOP src add-ons kernel drivers arch x86 floppy ;
|
||||||
|
|
||||||
|
SetSubDirSupportedPlatformsBeOSCompatible ;
|
||||||
|
|
||||||
|
UsePrivateHeaders drivers kernel ;
|
||||||
|
|
||||||
KernelAddon floppy :
|
KernelAddon floppy :
|
||||||
floppy.c
|
floppy.c
|
||||||
floppy_ctrl.c
|
floppy_ctrl.c
|
||||||
device_icons.c
|
device_icons.c
|
||||||
;
|
;
|
||||||
|
|
||||||
# Not ready for prime-time yet: R5 floppy driver replacement at the moment.
|
|
||||||
|
|
||||||
# KernelObjects
|
|
||||||
# floppy.c
|
|
||||||
# floppy_ctrl.c
|
|
||||||
# device_icons.c
|
|
||||||
# :
|
|
||||||
# -fno-pic -D_KERNEL_MODE
|
|
||||||
# ;
|
|
||||||
#
|
|
||||||
# KernelLd floppy :
|
|
||||||
# <$(SOURCE_GRIST)>floppy.o
|
|
||||||
# <$(SOURCE_GRIST)>floppy_ctrl.o
|
|
||||||
# <$(SOURCE_GRIST)>device_icons.o
|
|
||||||
# kernel.so
|
|
||||||
# :
|
|
||||||
# $(HAIKU_TOP)/src/kernel/ldscripts/$(TARGET_ARCH)/add-on.ld
|
|
||||||
# :
|
|
||||||
# -Bdynamic -shared
|
|
||||||
# :
|
|
||||||
# :
|
|
||||||
# drivers/dev/floppy
|
|
||||||
# ;
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* OpenBeOS floppy driver
|
* Copyright 2003-2008, Haiku.
|
||||||
* (c) 2003, OpenBeOS project.
|
* Distributed under the terms of the MIT License.
|
||||||
* François Revol, [email protected]
|
*
|
||||||
|
* Authors:
|
||||||
|
* François Revol <[email protected]>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
const char floppy_icon[] = {
|
const char floppy_icon[] = {
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* OpenBeOS floppy driver
|
* Copyright 2003-2008, Haiku.
|
||||||
* (c) 2003, OpenBeOS project.
|
* Distributed under the terms of the MIT License.
|
||||||
* François Revol, [email protected]
|
*
|
||||||
|
* Authors:
|
||||||
|
* François Revol <[email protected]>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* OpenBeOS floppy driver
|
* Copyright 2003-2008, Haiku.
|
||||||
* (c) 2003, OpenBeOS project.
|
* Distributed under the terms of the MIT License.
|
||||||
* François Revol, [email protected]
|
*
|
||||||
|
* Authors:
|
||||||
|
* François Revol <[email protected]>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _FLOPPY_H
|
#ifndef _FLOPPY_H
|
||||||
@@ -10,7 +12,21 @@
|
|||||||
#include <Drivers.h>
|
#include <Drivers.h>
|
||||||
#include <ISA.h>
|
#include <ISA.h>
|
||||||
#include <KernelExport.h>
|
#include <KernelExport.h>
|
||||||
|
|
||||||
|
// TODO: switch to native lock.
|
||||||
|
#ifdef __HAIKU__
|
||||||
|
#include <lock.h>
|
||||||
|
typedef recursive_lock lock;
|
||||||
|
#define new_lock recursive_lock_init
|
||||||
|
#define free_lock recursive_lock_destroy
|
||||||
|
#define LOCK(l) recursive_lock_lock(&l);
|
||||||
|
#define UNLOCK(l) recursive_lock_unlock(&l);
|
||||||
|
#else
|
||||||
|
#ifndef _IMPEXP_KERNEL
|
||||||
|
#define _IMPEXP_KERNEL
|
||||||
|
#endif
|
||||||
#include "lock.h"
|
#include "lock.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
#define FLO "floppy: "
|
#define FLO "floppy: "
|
||||||
#if defined(DEBUG) && DEBUG > 0
|
#if defined(DEBUG) && DEBUG > 0
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* OpenBeOS floppy driver
|
* Copyright 2003-2008, Haiku.
|
||||||
* (c) 2003, OpenBeOS project.
|
* Distributed under the terms of the MIT License.
|
||||||
* François Revol, [email protected]
|
*
|
||||||
|
* Authors:
|
||||||
|
* François Revol <[email protected]>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user