Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Jun 2012 12:04:34 +0200
From:      Henri Hennebert <hlh@restart.be>
To:        Mitya <mitya@cabletv.dp.ua>
Cc:        freebsd-stable@freebsd.org
Subject:   Re: Can not build kernel with modular ata and ATA_CAM
Message-ID:  <4FE837B2.6090507@restart.be>
In-Reply-To: <4FE8264B.2010302@cabletv.dp.ua>
References:  <4FE8264B.2010302@cabletv.dp.ua>

next in thread | previous in thread | raw e-mail | index | archive | help
On 06/25/2012 10:50, Mitya wrote:
> My kernel options:
>
> # Bus support.
> device          acpi
> device          pci
>
> # Modular ATA
> device          atadisk         # ATA disk drives
> device          atacore         # Core ATA functionality
> device          atapci          # PCI bus support; only generic chipset
> support
> device          ataintel        # Intel
>
> options         ATA_CAM         # Handle legacy controllers with CAM
> options         ATA_STATIC_ID   # Static device numbering
>
> # ATA/SCSI peripherals
> device          scbus           # SCSI bus (required for ATA/SCSI)
> device          da              # Direct Access (disks)
> device          pass            # Passthrough device (direct ATA/SCSI
> access)

 From /usr/src/sys/conf/NOTES:

# ATA_CAM:              Turn ata(4) subsystem controller drivers into cam(4)
#                       interface modules. This deprecates all ata(4)
#                       peripheral device drivers (atadisk, ataraid, 
atapicd,
#                       atapifd, atapist, atapicam) and all user-level APIs.
#                       cam(4) drivers and APIs will be connected instead.


So you must remove 'device          atadisk'

Henri


>
> make's output:
>
> ata-disk.o: In function `ad_init':
> ata-disk.c:(.text+0x7d): undefined reference to `ata_setmode'
> ata-disk.c:(.text+0x95): undefined reference to `ata_wc'
> ata-disk.c:(.text+0xc9): undefined reference to `ata_controlcmd'
> ata-disk.c:(.text+0x11b): undefined reference to `ata_controlcmd'
> ata-disk.c:(.text+0x16d): undefined reference to `ata_controlcmd'
> ata-disk.c:(.text+0x1b6): undefined reference to `ata_controlcmd'
> ata-disk.o: In function `ad_shutdown':
> ata-disk.c:(.text+0x258): undefined reference to `ata_controlcmd'
> ata-disk.o: In function `ad_detach':
> ata-disk.c:(.text+0x479): undefined reference to `ata_fail_requests'
> ata-disk.o: In function `ad_dump':
> ata-disk.c:(.text+0x861): undefined reference to `ata_drop_requests'
> ata-disk.c:(.text+0x921): undefined reference to `ata_controlcmd'
> ata-disk.o: In function `ad_attach':
> ata-disk.c:(.text+0xa40): undefined reference to `ata_setmax'
> ata-disk.c:(.text+0xb62): undefined reference to `ata_satarev2str'
> ata-disk.c:(.text+0xba7): undefined reference to `ata_unit2str'
> ata-disk.c:(.text+0xfff): undefined reference to `ata_queue_request'
> ata-disk.c:(.text+0x131e): undefined reference to `ata_queue_request'
> ata-disk.c:(.text+0x1340): undefined reference to `ata_getparam'
> ata-disk.o: In function `ad_spindown':
> ata-disk.c:(.text+0x539): undefined reference to `ata_queue_request'
> ata-disk.o: In function `ad_ioctl':
> ata-disk.c:(.text+0x5a4): undefined reference to `ata_device_ioctl'
> ata-disk.o: In function `ad_strategy':
> ata-disk.c:(.text+0x6c7): undefined reference to `ata_queue_request'
> *** [kernel] Error code 1
>
> I found differences in ata-all.c and ata-all.h
>
> In ata-all.c:
> #ifndef ATA_CAM
> void
> ata_setmode(device_t dev)
> {
>
> But, in ata-all.h:
> void ata_setmode(device_t dev);
>
> without any #ifdef or #ifndef
>
>
>
>
>
>
>
> _______________________________________________
> freebsd-stable@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-stable
> To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org"
>





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4FE837B2.6090507>