Explicitly pass vnode to smbfs_doio() function.

This commit is contained in:
Poul-Henning Kamp 2004-09-07 08:53:28 +00:00
parent 7ee3985c57
commit 066a8fea81
3 changed files with 3 additions and 6 deletions

View File

@ -98,7 +98,7 @@ struct smbmount {
#define VTOSMBFS(vp) (VFSTOSMBFS(VTOVFS(vp))) #define VTOSMBFS(vp) (VFSTOSMBFS(VTOVFS(vp)))
int smbfs_ioctl(struct vop_ioctl_args *ap); int smbfs_ioctl(struct vop_ioctl_args *ap);
int smbfs_doio(struct buf *bp, struct ucred *cr, struct thread *td); int smbfs_doio(struct vnode *vp, struct buf *bp, struct ucred *cr, struct thread *td);
int smbfs_vinvalbuf(struct vnode *vp, int flags, struct ucred *cred, int smbfs_vinvalbuf(struct vnode *vp, int flags, struct ucred *cred,
struct thread *td, int intrflg); struct thread *td, int intrflg);
#endif /* KERNEL */ #endif /* KERNEL */

View File

@ -303,9 +303,8 @@ smbfs_writevnode(struct vnode *vp, struct uio *uiop,
* Do an I/O operation to/from a cache block. * Do an I/O operation to/from a cache block.
*/ */
int int
smbfs_doio(struct buf *bp, struct ucred *cr, struct thread *td) smbfs_doio(struct vnode *vp, struct buf *bp, struct ucred *cr, struct thread *td)
{ {
struct vnode *vp = bp->b_vp;
struct smbmount *smp = VFSTOSMBFS(vp->v_mount); struct smbmount *smp = VFSTOSMBFS(vp->v_mount);
struct smbnode *np = VTOSMB(vp); struct smbnode *np = VTOSMB(vp);
struct uio uio, *uiop = &uio; struct uio uio, *uiop = &uio;

View File

@ -854,8 +854,6 @@ smbfs_strategy (ap)
struct thread *td; struct thread *td;
int error = 0; int error = 0;
KASSERT(ap->a_vp == ap->a_bp->b_vp, ("%s(%p != %p)",
__func__, ap->a_vp, ap->a_bp->b_vp));
SMBVDEBUG("\n"); SMBVDEBUG("\n");
if (bp->b_flags & B_ASYNC) if (bp->b_flags & B_ASYNC)
td = (struct thread *)0; td = (struct thread *)0;
@ -867,7 +865,7 @@ smbfs_strategy (ap)
cr = bp->b_wcred; cr = bp->b_wcred;
if ((bp->b_flags & B_ASYNC) == 0 ) if ((bp->b_flags & B_ASYNC) == 0 )
error = smbfs_doio(bp, cr, td); error = smbfs_doio(ap->a_vp, bp, cr, td);
return error; return error;
} }